{
    "Function": "slitherConstructorConstantVariables",
    "File": "contracts/upgrades/GraphProxy.sol",
    "Parent Contracts": [
        "contracts/upgrades/GraphProxyStorage.sol"
    ],
    "High-Level Calls": [],
    "Internal Calls": [],
    "Library Calls": [],
    "Low-Level Calls": [],
    "Code": "contract GraphProxy is GraphProxyStorage {\n    /**\n     * @dev Modifier used internally that will delegate the call to the implementation unless\n     * the sender is the admin.\n     */\n    modifier ifAdmin() {\n        if (msg.sender == _admin()) {\n            _;\n        } else {\n            _fallback();\n        }\n    }\n\n    /**\n     * @dev Modifier used internally that will delegate the call to the implementation unless\n     * the sender is the admin or pending implementation.\n     */\n    modifier ifAdminOrPendingImpl() {\n        if (msg.sender == _admin() || msg.sender == _pendingImplementation()) {\n            _;\n        } else {\n            _fallback();\n        }\n    }\n\n    /**\n     * @dev Contract constructor.\n     * @param _impl Address of the initial implementation\n     * @param _admin Address of the proxy admin\n     */\n    constructor(address _impl, address _admin) {\n        assert(ADMIN_SLOT == bytes32(uint256(keccak256(\"eip1967.proxy.admin\")) - 1));\n        assert(\n            IMPLEMENTATION_SLOT == bytes32(uint256(keccak256(\"eip1967.proxy.implementation\")) - 1)\n        );\n        assert(\n            PENDING_IMPLEMENTATION_SLOT ==\n                bytes32(uint256(keccak256(\"eip1967.proxy.pendingImplementation\")) - 1)\n        );\n\n        _setAdmin(_admin);\n        _setPendingImplementation(_impl);\n    }\n\n    /**\n     * @dev Returns the current admin.\n     *\n     * NOTE: Only the admin and implementation can call this function.\n     *\n     * TIP: To get this value clients can read directly from the storage slot shown below (specified by EIP1967) using the\n     * https://eth.wiki/json-rpc/API#eth_getstorageat[`eth_getStorageAt`] RPC call.\n     * `0xb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d6103`\n     */\n    function admin() external ifAdminOrPendingImpl returns (address) {\n        return _admin();\n    }\n\n    /**\n     * @dev Returns the current implementation.\n     *\n     * NOTE: Only the admin can call this function.\n     *\n     * TIP: To get this value clients can read directly from the storage slot shown below (specified by EIP1967) using the\n     * https://eth.wiki/json-rpc/API#eth_getstorageat[`eth_getStorageAt`] RPC call.\n     * `0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc`\n     */\n    function implementation() external ifAdminOrPendingImpl returns (address) {\n        return _implementation();\n    }\n\n    /**\n     * @dev Returns the current pending implementation.\n     *\n     * NOTE: Only the admin can call this function.\n     *\n     * TIP: To get this value clients can read directly from the storage slot shown below (specified by EIP1967) using the\n     * https://eth.wiki/json-rpc/API#eth_getstorageat[`eth_getStorageAt`] RPC call.\n     * `0x9e5eddc59e0b171f57125ab86bee043d9128098c3a6b9adb4f2e86333c2f6f8c`\n     */\n    function pendingImplementation() external ifAdminOrPendingImpl returns (address) {\n        return _pendingImplementation();\n    }\n\n    /**\n     * @dev Changes the admin of the proxy.\n     *\n     * NOTE: Only the admin can call this function.\n     */\n    function setAdmin(address _newAdmin) external ifAdmin {\n        require(_newAdmin != address(0), \"Cannot change the admin of a proxy to the zero address\");\n        _setAdmin(_newAdmin);\n    }\n\n    /**\n     * @dev Upgrades to a new implementation contract.\n     * @param _newImplementation Address of implementation contract\n     *\n     * NOTE: Only the admin can call this function.\n     */\n    function upgradeTo(address _newImplementation) external ifAdmin {\n        _setPendingImplementation(_newImplementation);\n    }\n\n    /**\n     * @dev Admin function for new implementation to accept its role as implementation.\n     */\n    function acceptUpgrade() external ifAdminOrPendingImpl {\n        _acceptUpgrade();\n    }\n\n    /**\n     * @dev Admin function for new implementation to accept its role as implementation.\n     */\n    function acceptUpgradeAndCall(bytes calldata data) external ifAdminOrPendingImpl {\n        _acceptUpgrade();\n        // solhint-disable-next-line avoid-low-level-calls\n        (bool success, ) = _implementation().delegatecall(data);\n        require(success);\n    }\n\n    /**\n     * @dev Admin function for new implementation to accept its role as implementation.\n     */\n    function _acceptUpgrade() internal {\n        address _pendingImplementation = _pendingImplementation();\n        require(Address.isContract(_pendingImplementation), \"Implementation must be a contract\");\n        require(\n            _pendingImplementation != address(0) && msg.sender == _pendingImplementation,\n            \"Caller must be the pending implementation\"\n        );\n\n        _setImplementation(_pendingImplementation);\n        _setPendingImplementation(address(0));\n    }\n\n    /**\n     * @dev Delegates the current call to implementation.\n     * This function does not return to its internal call site, it will return directly to the\n     * external caller.\n     */\n    function _fallback() internal {\n        require(msg.sender != _admin(), \"Cannot fallback to proxy target\");\n\n        assembly {\n            // (a) get free memory pointer\n            let ptr := mload(0x40)\n\n            // (b) get address of the implementation\n            let impl := and(sload(IMPLEMENTATION_SLOT), 0xffffffffffffffffffffffffffffffffffffffff)\n\n            // (1) copy incoming call data\n            calldatacopy(ptr, 0, calldatasize())\n\n            // (2) forward call to logic contract\n            let result := delegatecall(gas(), impl, ptr, calldatasize(), 0, 0)\n            let size := returndatasize()\n\n            // (3) retrieve return data\n            returndatacopy(ptr, 0, size)\n\n            // (4) forward return data back to caller\n            switch result\n            case 0 {\n                revert(ptr, size)\n            }\n            default {\n                return(ptr, size)\n            }\n        }\n    }\n\n    /**\n     * @dev Fallback function that delegates calls to implementation. Will run if no other\n     * function in the contract matches the call data.\n     */\n    fallback() external payable {\n        _fallback();\n    }\n\n    /**\n     * @dev Fallback function that delegates calls to implementation. Will run if call data\n     * is empty.\n     */\n    receive() external payable {\n        _fallback();\n    }\n}"
}