The divideNft
function in the TokenDivider contract has the onlyNftOwner
modifier applied twice, which is redundant and wastes gas.
In the divideNft
function declaration, the onlyNftOwner
modifier is used twice with the same parameters:
This causes the ownership check to be performed twice unnecessarily.
Increased gas costs due to redundant checks
Code readability issues
No security impact as the duplicate check doesn't change the function's behavior
Manual code review
Remove one instance of the modifier:
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.