{
    "Function": "_removeStrategyFromStakerStrategyList",
    "File": "src/contracts/core/StrategyManager.sol",
    "Parent Contracts": [
        "src/contracts/core/StrategyManagerStorage.sol",
        "src/contracts/interfaces/IStrategyManager.sol",
        "src/contracts/permissions/Pausable.sol",
        "src/contracts/interfaces/IPausable.sol",
        "lib/openzeppelin-contracts-upgradeable/contracts/security/ReentrancyGuardUpgradeable.sol",
        "lib/openzeppelin-contracts-upgradeable/contracts/access/OwnableUpgradeable.sol",
        "lib/openzeppelin-contracts-upgradeable/contracts/utils/ContextUpgradeable.sol",
        "lib/openzeppelin-contracts-upgradeable/contracts/proxy/utils/Initializable.sol"
    ],
    "High-Level Calls": [],
    "Internal Calls": [
        "require(bool,string)"
    ],
    "Library Calls": [],
    "Low-Level Calls": [],
    "Code": "function _removeStrategyFromStakerStrategyList(address depositor, uint256 strategyIndex, IStrategy strategy) internal {\n        // if the strategy matches with the strategy index provided\n        if (stakerStrategyList[depositor][strategyIndex] == strategy) {\n            // replace the strategy with the last strategy in the list\n            stakerStrategyList[depositor][strategyIndex] =\n                stakerStrategyList[depositor][stakerStrategyList[depositor].length - 1];\n        } else {\n            //loop through all of the strategies, find the right one, then replace\n            uint256 stratsLength = stakerStrategyList[depositor].length;\n            uint256 j = 0;\n            for (; j < stratsLength;) {\n                if (stakerStrategyList[depositor][j] == strategy) {\n                    //replace the strategy with the last strategy in the list\n                    stakerStrategyList[depositor][j] = stakerStrategyList[depositor][stakerStrategyList[depositor].length - 1];\n                    break;\n                }\n                unchecked {\n                    ++j;\n                }\n            }\n            // if we didn't find the strategy, revert\n            require(j != stratsLength, \"StrategyManager._removeStrategyFromStakerStrategyList: strategy not found\");\n        }\n        // pop off the last entry in the list of strategies\n        stakerStrategyList[depositor].pop();\n    }"
}