Steadefi

Steadefi
DeFiHardhatFoundryOracle
35,000 USDC
View results
Submission Details
Severity: low
Invalid

Unused Imports should be removed

Summary

Unused imports should be removed from file.

Vulnerability Details

There are some situations where unused imports result to accessing a function which the developer isn't aware is part of smart contract logic. In this case, it isn't a severe impact but still a bad practice.

Impact

in file contracts\strategy\gmx\GMXChecks.sol:

import { IERC20 } from "@openzeppelin/contracts/token/ERC20/IERC20.sol";
- import { IDeposit } from "../../interfaces/protocols/gmx/IDeposit.sol";
- import { IWithdrawal } from "../../interfaces/protocols/gmx/IWithdrawal.sol";
- import { IEvent } from "../../interfaces/protocols/gmx/IEvent.sol";
- import { IOrder } from "../../interfaces/protocols/gmx/IOrder.sol";
import { Errors } from "../../utils/Errors.sol";
import { GMXTypes } from "./GMXTypes.sol";
import { GMXReader } from "./GMXReader.sol";

in file contracts\strategy\gmx\GMXDeposit.sol:

import { IERC20 } from "@openzeppelin/contracts/token/ERC20/IERC20.sol";
import { SafeERC20 } from "@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol";
- import { IDeposit } from "../../interfaces/protocols/gmx/IDeposit.sol";
- import { IWithdrawal } from "../../interfaces/protocols/gmx/IWithdrawal.sol";
- import { IEvent } from "../../interfaces/protocols/gmx/IEvent.sol";
- import { IOrder } from "../../interfaces/protocols/gmx/IOrder.sol";
import { ISwap } from "../../interfaces/swap/ISwap.sol";
import { GMXTypes } from "./GMXTypes.sol";
import { GMXReader } from "./GMXReader.sol";
import { GMXChecks } from "./GMXChecks.sol";
import { GMXManager } from "./GMXManager.sol";
import { GMXProcessDeposit } from "./GMXProcessDeposit.sol";

in file contracts\strategy\gmx\GMXTrove.sol:

- import { IERC20 } from "@openzeppelin/contracts/token/ERC20/IERC20.sol";
- import { SafeERC20 } from "@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol";
import { IGMXVault } from "../../interfaces/strategy/gmx/IGMXVault.sol";
import { GMXTypes } from "./GMXTypes.sol";

Tools Used

Manual Review

Recommendations

Remove as shown above

Updates

Lead Judging Commences

hans Lead Judge almost 2 years ago
Submission Judgement Published
Invalidated
Reason: Non-acceptable severity
Assigned finding tags:

INFO: Unused imports

Support

FAQs

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