code-423n4 / 2022-01-trader-joe-findings

2 stars 0 forks source link

`Ownable` library is redundant #241

Open code423n4 opened 2 years ago

code423n4 commented 2 years ago

Handle

WatchPug

Vulnerability details

https://github.com/code-423n4/2022-01-trader-joe/blob/a1579f6453bc4bf9fb0db9c627beaa41135438ed/contracts/LaunchEvent.sol#L19-L19

contract LaunchEvent is Ownable {

The LaunchEvent.sol contract never utilized onlyOwner / owner() or any other features provided by the Ownable library.

Therefore, is Ownable can be removed.

cryptofish7 commented 2 years ago

Should be 0 severity.

Fix; https://github.com/traderjoe-xyz/rocket-joe/commit/989bb6ccf0b44b8f7f120a5f893b701118c1d9a6

dmvt commented 2 years ago

Leaving the unnecessary contract out will save gas depending on how you deploy.