Smart Contract

Enable native meta transactions in your Smart Contract

This section explains how you can enable native meta transactions in your smart contract. It means we have to get rid of msg.sender and msg.value properties in our code.

But we still need to identify the user address to add the ownership details in smart contract. We can't take the user address as a function parameter as anyone can pass any value in that.

More secure way to do this is to take an extra parameter signature in our setQuote method and extract the user address from the signature.

Move to next section to see the code changes in our smart contract.

Last updated