Open code423n4 opened 2 years ago
ye0lde
Removing the unused local variables improves code clarity.
Suggest changing to (uint256[] memory amounts,) https://github.com/code-423n4/2021-11-nested/blob/f646002b692ca5fa3631acfff87dda897541cf41/contracts/NestedFactory.sol#L379 https://github.com/code-423n4/2021-11-nested/blob/f646002b692ca5fa3631acfff87dda897541cf41/contracts/NestedFactory.sol#L410
(uint256[] memory amounts,)
Visual Studio Code, Remix
Remove the unused variables - See POC
Duplicated #67 & #66
Taking this as main.
Handle
ye0lde
Vulnerability details
Impact
Removing the unused local variables improves code clarity.
Proof of Concept
Suggest changing to
(uint256[] memory amounts,)
https://github.com/code-423n4/2021-11-nested/blob/f646002b692ca5fa3631acfff87dda897541cf41/contracts/NestedFactory.sol#L379 https://github.com/code-423n4/2021-11-nested/blob/f646002b692ca5fa3631acfff87dda897541cf41/contracts/NestedFactory.sol#L410Tools Used
Visual Studio Code, Remix
Recommended Mitigation Steps
Remove the unused variables - See POC