QuantAMM

QuantAMM
49,600 OP
View results
Submission Details
Severity: low
Invalid

Importing same file multiple times in the code

Summary

Importing the same file "QuantAMMStorage.sol" two times in QuantAMMWeightedPool.sol contract. There is no major impact as it will be handled by compiled. Hence keeping it low. it’s good practice to avoid redundant imports for better code readability and maintenance

Vulnerability Details

https://github.com/Cyfrin/2024-12-quantamm/blob/be3b44f8301bb44d709788c6f28a9abb3e0ddb43/pkg/pool-quantamm/contracts/QuantAMMWeightedPool.sol#L31

https://github.com/Cyfrin/2024-12-quantamm/blob/be3b44f8301bb44d709788c6f28a9abb3e0ddb43/pkg/pool-quantamm/contracts/QuantAMMWeightedPool.sol#L35

Impact

There is no major impact as it will be handled by compiled. it’s good practice to avoid redundant imports for better code readability and maintenance

Tools Used

Manual review

Recommendations

remove the duplicate import statement done here

https://github.com/Cyfrin/2024-12-quantamm/blob/be3b44f8301bb44d709788c6f28a9abb3e0ddb43/pkg/pool-quantamm/contracts/QuantAMMWeightedPool.sol#L35

Updates

Lead Judging Commences

n0kto Lead Judge 4 months ago
Submission Judgement Published
Invalidated
Reason: Non-acceptable severity
Assigned finding tags:

Informational or Gas / Admin is trusted / Pool creation is trusted / User mistake / Suppositions

Please read the CodeHawks documentation to know which submissions are valid. If you disagree, provide a coded PoC and explain the real likelyhood and the detailed impact on the mainnet without any supposition (if, it could, etc) to prove your point.

Support

FAQs

Can't find an answer? Chat with us on Discord, Twitter or Linkedin.