{
    "Function": "claimRewards",
    "File": "contracts/ExtraRewardStashV3.sol",
    "Parent Contracts": [],
    "High-Level Calls": [
        "IDeposit",
        "IDeposit"
    ],
    "Internal Calls": [
        "require(bool,string)",
        "checkForNewRewardTokens"
    ],
    "Library Calls": [],
    "Low-Level Calls": [],
    "Code": "function claimRewards() external returns (bool) {\n        require(msg.sender == operator, \"!authorized\");\n\n        //this is updateable from v2 gauges now so must check each time.\n        checkForNewRewardTokens();\n\n        //make sure we're redirected\n        if (!hasRedirected) {\n            IDeposit(operator).setGaugeRedirect(pid);\n            hasRedirected = true;\n        }\n\n        uint256 length = tokenCount;\n        if (length > 0) {\n            //claim rewards on gauge for staker\n            //using reward_receiver so all rewards will be moved to this stash\n            IDeposit(operator).claimRewards(pid, gauge);\n        }\n        return true;\n    }"
}