We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Usage of non-equal operator against zero consumes more gas
The contract : https://github.com/code-423n4/2022-06-connext/blob/main/contracts/contracts/core/connext/helpers/LPToken.sol at line 35 checks if the amount isn't 0 " require(amount != 0, "LPToken: cannot mint 0"); " , this likely consumes more gas while it can do the same work by making the higher-than operator
Consider using :
require(amount>0, "LPToken: cannot mint 0");
instead of
require(amount != 0, "LPToken: cannot mint 0");
The text was updated successfully, but these errors were encountered:
orion issue #4
5c3b8e4
Invalid See #274
Sorry, something went wrong.
No branches or pull requests
Usage of non-equal operator against zero consumes more gas
The contract : https://github.com/code-423n4/2022-06-connext/blob/main/contracts/contracts/core/connext/helpers/LPToken.sol at line 35
checks if the amount isn't 0 " require(amount != 0, "LPToken: cannot mint 0");
" , this likely consumes more gas while it can do the same work by making the higher-than operator
Consider using :
instead of
The text was updated successfully, but these errors were encountered: