{
    "Function": "_depositIntoStrategy",
    "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": [
        "SafeERC20",
        "IStrategy"
    ],
    "Internal Calls": [
        "onlyStrategiesWhitelistedForDeposit",
        "_addShares"
    ],
    "Library Calls": [
        "safeTransferFrom"
    ],
    "Low-Level Calls": [],
    "Code": "function _depositIntoStrategy(address depositor, IStrategy strategy, IERC20 token, uint256 amount)\n        internal\n        onlyStrategiesWhitelistedForDeposit(strategy)\n        returns (uint256 shares)\n    {\n        // transfer tokens from the sender to the strategy\n        token.safeTransferFrom(msg.sender, address(strategy), amount);\n\n        // deposit the assets into the specified strategy and get the equivalent amount of shares in that strategy\n        shares = strategy.deposit(token, amount);\n\n        // add the returned shares to the depositor's existing shares for this strategy\n        _addShares(depositor, strategy, shares);\n\n        emit Deposit(depositor, token, strategy, shares);\n\n        return shares;\n    }"
}