We can send a er20 token to a smart contract.
To track it we can use a function
( msg.value is always wei )
But how do i verify if the erc20 token is actually sent ?
For example i want to set map true if the person sent > 5 vbcoins
function sendVBCoins(uint256 _howmuch){
require(_howmuch >= 5);
goodperson[msg.sender] = true;
}
Anyone can send 1 wei and call that function and become goodperson
.
How do i solve it ?