example:
function addAllowedTokens(address _token) public onlyOwner {
if (!tokenIsAllowed(_token)) {
allowedTokens[_token] = true;
}
}
In this code, the allowedTokens
mapping won't always be modified? I have a test that calls this functions and doesn't modify the mapping, and it passes but a lot of weird console stuff gets printed.
MORAL OF QUESTION IS: WHAT HAPPENS WHEN A NON-VIEW FUNCTION IS CALLED AND DOESN'T MODIFY THE SMART CONTRACT?
My intuition is that this should be fine and just run. But seems like something different may be happening.