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
Require statements including conditions with the && operator can be broken down in multiple require statements to save gas.
&&
Instances include:
require( _disputeID < disputeCount && disputes[_disputeID].status == Status.Active, "Disputes::!Resolvable" );
require( _actionType > 0 && _actionType <= uint8(ActionType.TaskPay), "Disputes::!ActionType" );
require( _lendingNeeded >= _communityProject.totalLent && _lendingNeeded <= IProject(_project).projectCost(), "Community::invalid lending" );
Breakdown each condition in a separate require statement
require
require( _disputeID < disputeCount); require(disputes[_disputeID].status == Status.Active, "Disputes::!Resolvable" );
The text was updated successfully, but these errors were encountered:
dharma09 issue #26
a4cd94a
thanks for your work
Sorry, something went wrong.
No branches or pull requests
IMPACT
Require statements including conditions with the
&&
operator can be broken down in multiple require statements to save gas.PROOF OF CONCEPT
Instances include:
Disputes.sol#L61
Disputes.sol#L106
Community.sol#L353
MITIGATION
Breakdown each condition in a separate
require
statementThe text was updated successfully, but these errors were encountered: