There was a loophole with this approach as highlighted by a member of the Terraswap team. As a result it was decided that it would be better to whitelist dapp contracts (similar to Binance whitelisting).
This has been discussed here:
And also here: