Functions that are never called throughout the contract should be marked as external visibility instead of public visibility to avoid the unnecessary copying of data to memory.
This will effectively result in Gas Optimization.
Therefore, the following function must be marked as external:
Factory.sol
setMinLicenseFee()
setAuctionDecrement()
setAuctionMultiplier()
setBondPercentDiv()
setOwnerSplit()
proposeBasketLicense()
Basket.sol
initialize()
mint()
burn()
changePublisher()
changeLicenseFee()
publishNewIndex()
deleteNewIndex()
Auction.sol
initialize()
bondForRebalance()
settleAuction()
addBounty()
startAuction()
killAuction()
Recommended Mitigation Steps
The above-mentioned functions should be assigned external visibility, and the parameter storage location should be set as calldata rather than memory.
Handle
WatchPug
Vulnerability details
Functions that are never called throughout the contract should be marked as external visibility instead of public visibility to avoid the unnecessary copying of data to memory.
This will effectively result in Gas Optimization.
Therefore, the following function must be marked as external:
Factory.sol
Basket.sol
Auction.sol
Recommended Mitigation Steps
The above-mentioned functions should be assigned external visibility, and the parameter storage location should be set as
calldata
rather than memory.