Skip to content
New issue

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

[CodeArena] - [L-05] : safeApprove shouldn't be used #54

Merged
merged 1 commit into from
Dec 3, 2021

Conversation

maximebrugel
Copy link
Contributor

Issue => code-423n4/2021-11-nested-findings#50

I removed the if (_currentAllowance == 0) condition, it saves gas (on average).

@maximebrugel maximebrugel added the To review Let people know this PR is ready for a review label Dec 2, 2021
@maximebrugel
Copy link
Contributor Author

maximebrugel commented Dec 2, 2021

Also, the "Recommended Mitigation Steps" in the issue is not working, since you can't safeIncreaseAllowance if the current allowance is not zero (overflow).

@maximebrugel maximebrugel added Can merge Good to go and removed To review Let people know this PR is ready for a review labels Dec 3, 2021
@maximebrugel maximebrugel merged commit 3b0e7e5 into codearena Dec 3, 2021
@maximebrugel maximebrugel deleted the codearena-50 branch December 3, 2021 08:28
@maximebrugel maximebrugel changed the title [CodeArena] - Issue 50 : safeApprove shouldn't be used [CodeArena] - [L-05] : safeApprove shouldn't be used Dec 8, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Can merge Good to go
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants