{
  "contractName": "SimpleDAIStaking",
  "abi": [
    {
      "inputs": [
        {
          "internalType": "address",
          "name": "_dai",
          "type": "address"
        },
        {
          "internalType": "address",
          "name": "_cDai",
          "type": "address"
        },
        {
          "internalType": "address",
          "name": "_fundManager",
          "type": "address"
        },
        {
          "internalType": "uint256",
          "name": "_blockInterval",
          "type": "uint256"
        },
        {
          "internalType": "contract Avatar",
          "name": "_avatar",
          "type": "address"
        },
        {
          "internalType": "contract Identity",
          "name": "_identity",
          "type": "address"
        }
      ],
      "payable": false,
      "stateMutability": "nonpayable",
      "type": "constructor"
    },
    {
      "anonymous": false,
      "inputs": [
        {
          "indexed": true,
          "internalType": "address",
          "name": "staker",
          "type": "address"
        },
        {
          "indexed": false,
          "internalType": "uint256",
          "name": "daiValue",
          "type": "uint256"
        },
        {
          "indexed": false,
          "internalType": "uint256",
          "name": "daiActual",
          "type": "uint256"
        }
      ],
      "name": "DAIStakeWithdraw",
      "type": "event"
    },
    {
      "anonymous": false,
      "inputs": [
        {
          "indexed": true,
          "internalType": "address",
          "name": "staker",
          "type": "address"
        },
        {
          "indexed": false,
          "internalType": "uint256",
          "name": "daiValue",
          "type": "uint256"
        }
      ],
      "name": "DAIStaked",
      "type": "event"
    },
    {
      "anonymous": false,
      "inputs": [
        {
          "indexed": false,
          "internalType": "address",
          "name": "recipient",
          "type": "address"
        },
        {
          "indexed": false,
          "internalType": "uint256",
          "name": "cdaiValue",
          "type": "uint256"
        },
        {
          "indexed": false,
          "internalType": "uint256",
          "name": "daiValue",
          "type": "uint256"
        },
        {
          "indexed": false,
          "internalType": "uint256",
          "name": "daiPrecisionLoss",
          "type": "uint256"
        }
      ],
      "name": "InterestCollected",
      "type": "event"
    },
    {
      "anonymous": false,
      "inputs": [
        {
          "indexed": true,
          "internalType": "address",
          "name": "previousOwner",
          "type": "address"
        },
        {
          "indexed": true,
          "internalType": "address",
          "name": "newOwner",
          "type": "address"
        }
      ],
      "name": "OwnershipTransferred",
      "type": "event"
    },
    {
      "anonymous": false,
      "inputs": [
        {
          "indexed": false,
          "internalType": "address",
          "name": "account",
          "type": "address"
        }
      ],
      "name": "Paused",
      "type": "event"
    },
    {
      "anonymous": false,
      "inputs": [
        {
          "indexed": true,
          "internalType": "address",
          "name": "account",
          "type": "address"
        }
      ],
      "name": "PauserAdded",
      "type": "event"
    },
    {
      "anonymous": false,
      "inputs": [
        {
          "indexed": true,
          "internalType": "address",
          "name": "account",
          "type": "address"
        }
      ],
      "name": "PauserRemoved",
      "type": "event"
    },
    {
      "anonymous": false,
      "inputs": [
        {
          "indexed": false,
          "internalType": "address",
          "name": "account",
          "type": "address"
        }
      ],
      "name": "Unpaused",
      "type": "event"
    },
    {
      "constant": false,
      "inputs": [
        {
          "internalType": "address",
          "name": "account",
          "type": "address"
        }
      ],
      "name": "addPauser",
      "outputs": [],
      "payable": false,
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "avgInterestDonatedRatio",
      "outputs": [
        {
          "internalType": "uint32",
          "name": "",
          "type": "uint32"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "blockInterval",
      "outputs": [
        {
          "internalType": "uint256",
          "name": "",
          "type": "uint256"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "cDai",
      "outputs": [
        {
          "internalType": "contract cERC20",
          "name": "",
          "type": "address"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "dai",
      "outputs": [
        {
          "internalType": "contract ERC20",
          "name": "",
          "type": "address"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "fundManager",
      "outputs": [
        {
          "internalType": "address",
          "name": "",
          "type": "address"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "identity",
      "outputs": [
        {
          "internalType": "contract Identity",
          "name": "",
          "type": "address"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "isOwner",
      "outputs": [
        {
          "internalType": "bool",
          "name": "",
          "type": "bool"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [
        {
          "internalType": "address",
          "name": "account",
          "type": "address"
        }
      ],
      "name": "isPauser",
      "outputs": [
        {
          "internalType": "bool",
          "name": "",
          "type": "bool"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "isRegistered",
      "outputs": [
        {
          "internalType": "bool",
          "name": "",
          "type": "bool"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [
        {
          "internalType": "address",
          "name": "scheme",
          "type": "address"
        }
      ],
      "name": "isRegistered",
      "outputs": [
        {
          "internalType": "bool",
          "name": "",
          "type": "bool"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "lastUBICollection",
      "outputs": [
        {
          "internalType": "uint256",
          "name": "",
          "type": "uint256"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "owner",
      "outputs": [
        {
          "internalType": "address",
          "name": "",
          "type": "address"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": false,
      "inputs": [],
      "name": "pause",
      "outputs": [],
      "payable": false,
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "paused",
      "outputs": [
        {
          "internalType": "bool",
          "name": "",
          "type": "bool"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": false,
      "inputs": [],
      "name": "renounceOwnership",
      "outputs": [],
      "payable": false,
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "constant": false,
      "inputs": [],
      "name": "renouncePauser",
      "outputs": [],
      "payable": false,
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "constant": false,
      "inputs": [
        {
          "internalType": "contract Avatar",
          "name": "_avatar",
          "type": "address"
        }
      ],
      "name": "setAvatar",
      "outputs": [],
      "payable": false,
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "constant": false,
      "inputs": [
        {
          "internalType": "contract Identity",
          "name": "_identity",
          "type": "address"
        }
      ],
      "name": "setIdentity",
      "outputs": [],
      "payable": false,
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [
        {
          "internalType": "address",
          "name": "",
          "type": "address"
        }
      ],
      "name": "stakers",
      "outputs": [
        {
          "internalType": "uint256",
          "name": "stakedDAI",
          "type": "uint256"
        },
        {
          "internalType": "uint256",
          "name": "lastStake",
          "type": "uint256"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "totalStaked",
      "outputs": [
        {
          "internalType": "uint256",
          "name": "",
          "type": "uint256"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": false,
      "inputs": [
        {
          "internalType": "address",
          "name": "newOwner",
          "type": "address"
        }
      ],
      "name": "transferOwnership",
      "outputs": [],
      "payable": false,
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "constant": false,
      "inputs": [],
      "name": "unpause",
      "outputs": [],
      "payable": false,
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "constant": false,
      "inputs": [
        {
          "internalType": "address",
          "name": "_fundManager",
          "type": "address"
        }
      ],
      "name": "setFundManager",
      "outputs": [],
      "payable": false,
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "constant": false,
      "inputs": [
        {
          "internalType": "uint256",
          "name": "_amount",
          "type": "uint256"
        }
      ],
      "name": "stakeDAI",
      "outputs": [],
      "payable": false,
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "constant": false,
      "inputs": [],
      "name": "withdrawStake",
      "outputs": [],
      "payable": false,
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "currentDAIWorth",
      "outputs": [
        {
          "internalType": "uint256",
          "name": "",
          "type": "uint256"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "currentUBIInterest",
      "outputs": [
        {
          "internalType": "uint256",
          "name": "",
          "type": "uint256"
        },
        {
          "internalType": "uint256",
          "name": "",
          "type": "uint256"
        },
        {
          "internalType": "uint256",
          "name": "",
          "type": "uint256"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": false,
      "inputs": [
        {
          "internalType": "address",
          "name": "_recipient",
          "type": "address"
        }
      ],
      "name": "collectUBIInterest",
      "outputs": [
        {
          "internalType": "uint256",
          "name": "",
          "type": "uint256"
        },
        {
          "internalType": "uint256",
          "name": "",
          "type": "uint256"
        },
        {
          "internalType": "uint256",
          "name": "",
          "type": "uint256"
        },
        {
          "internalType": "uint32",
          "name": "",
          "type": "uint32"
        }
      ],
      "payable": false,
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "canCollect",
      "outputs": [
        {
          "internalType": "bool",
          "name": "",
          "type": "bool"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": false,
      "inputs": [],
      "name": "start",
      "outputs": [],
      "payable": false,
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "constant": false,
      "inputs": [],
      "name": "end",
      "outputs": [],
      "payable": false,
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "constant": false,
      "inputs": [
        {
          "internalType": "contract ERC20",
          "name": "_token",
          "type": "address"
        }
      ],
      "name": "recover",
      "outputs": [],
      "payable": false,
      "stateMutability": "nonpayable",
      "type": "function"
    }
  ],
  "metadata": "{\"compiler\":{\"version\":\"0.5.16+commit.9c3226ce\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_dai\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_cDai\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_fundManager\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_blockInterval\",\"type\":\"uint256\"},{\"internalType\":\"contract Avatar\",\"name\":\"_avatar\",\"type\":\"address\"},{\"internalType\":\"contract Identity\",\"name\":\"_identity\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"staker\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"daiValue\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"daiActual\",\"type\":\"uint256\"}],\"name\":\"DAIStakeWithdraw\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"staker\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"daiValue\",\"type\":\"uint256\"}],\"name\":\"DAIStaked\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"cdaiValue\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"daiValue\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"daiPrecisionLoss\",\"type\":\"uint256\"}],\"name\":\"InterestCollected\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"previousOwner\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"OwnershipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"PauserAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"PauserRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"constant\":false,\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"addPauser\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"avgInterestDonatedRatio\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"blockInterval\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"cDai\",\"outputs\":[{\"internalType\":\"contract cERC20\",\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"canCollect\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"internalType\":\"address\",\"name\":\"_recipient\",\"type\":\"address\"}],\"name\":\"collectUBIInterest\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"currentDAIWorth\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"currentUBIInterest\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"dai\",\"outputs\":[{\"internalType\":\"contract ERC20\",\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"end\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"fundManager\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"identity\",\"outputs\":[{\"internalType\":\"contract Identity\",\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"isOwner\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"isPauser\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"isRegistered\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"internalType\":\"address\",\"name\":\"scheme\",\"type\":\"address\"}],\"name\":\"isRegistered\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"lastUBICollection\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"internalType\":\"contract ERC20\",\"name\":\"_token\",\"type\":\"address\"}],\"name\":\"recover\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"renounceOwnership\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"renouncePauser\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"internalType\":\"contract Avatar\",\"name\":\"_avatar\",\"type\":\"address\"}],\"name\":\"setAvatar\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"internalType\":\"address\",\"name\":\"_fundManager\",\"type\":\"address\"}],\"name\":\"setFundManager\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"internalType\":\"contract Identity\",\"name\":\"_identity\",\"type\":\"address\"}],\"name\":\"setIdentity\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"stakeDAI\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"stakers\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"stakedDAI\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"lastStake\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"start\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"totalStaked\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"withdrawStake\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"}],\"devdoc\":{\"methods\":{\"canCollect()\":{\"details\":\"Checks if enough blocks have passed so it would be possible to execute `collectUBIInterest` according to the length of `blockInterval`\",\"return\":\"(bool) True if enough blocks have passed\"},\"collectUBIInterest(address)\":{\"details\":\"Collects gained interest by fundmanager. Can be collected only once in an interval which is defined above.\",\"params\":{\"_recipient\":\"The recipient of cDAI gains\"},\"return\":\"(uint256, uint256, uint256, uint32) The interest in cDAI, the interest in DAI, the amount which is not covered by precision of DAI, how much of the generated interest is donated\"},\"constructor\":{\"details\":\"Constructor\",\"params\":{\"_avatar\":\"The avatar of the DAO\",\"_blockInterval\":\"How many blocks should be passed before the next execution of `collectUBIInterest`\",\"_cDai\":\"The address of cDAI\",\"_dai\":\"The address of DAI\",\"_fundManager\":\"The address of the fund manager contract\",\"_identity\":\"The identity contract\"}},\"currentDAIWorth()\":{\"details\":\"Calculates the worth of the staked cDAI tokens in DAI.\",\"return\":\"(uint256) The worth in DAI\"},\"currentUBIInterest()\":{\"details\":\"Calculates the current interest that was gained.\",\"return\":\"(uint256, uint256, uint256) The interest in cDAI, the interest in DAI, the amount which is not covered by precision of DAI\"},\"end()\":{\"details\":\"making the contract inactive NOTICE: this could theoretically result in future interest earned in cdai to remain locked but we dont expect any other stakers but us in SimpleDAIStaking\"},\"isOwner()\":{\"return\":\"true if `msg.sender` is the owner of the contract.\"},\"isRegistered()\":{\"details\":\"function to see if an avatar has been set and if this scheme is registered\",\"return\":\"true if scheme is registered\"},\"isRegistered(address)\":{\"details\":\"function to see if an avatar has been set and if this scheme is registered\",\"return\":\"true if scheme is registered\"},\"owner()\":{\"return\":\"the address of the owner.\"},\"pause()\":{\"details\":\"called by the owner to pause, triggers stopped state\"},\"paused()\":{\"return\":\"true if the contract is paused, false otherwise.\"},\"recover(address)\":{\"details\":\"method to recover any stuck erc20 tokens (ie  compound COMP)\",\"params\":{\"_token\":\"the ERC20 token to recover\"}},\"renounceOwnership()\":{\"details\":\"Allows the current owner to relinquish control of the contract.\"},\"setAvatar(address)\":{\"details\":\"Function to set a new avatar and controller for scheme can only be done by owner of scheme\"},\"setFundManager(address)\":{\"details\":\"Allows the DAO to change the fund manager contract address\",\"params\":{\"_fundManager\":\"Address of the new contract\"}},\"stakeDAI(uint256)\":{\"details\":\"Allows a staker to deposit DAI tokens. Notice that `approve` is needed to be executed before the execution of this method. Can be executed only when the contract is not paused.\",\"params\":{\"_amount\":\"The amount of DAI to stake\"}},\"start()\":{\"details\":\"Start function. Adds this contract to identity as a feeless scheme. Can only be called if scheme is registered\"},\"transferOwnership(address)\":{\"details\":\"Allows the current owner to transfer control of the contract to a newOwner.\",\"params\":{\"newOwner\":\"The address to transfer ownership to.\"}},\"unpause()\":{\"details\":\"called by the owner to unpause, returns to normal state\"},\"withdrawStake()\":{\"details\":\"Withdraws the sender staked DAI.\"}},\"title\":\"Staking contract that donates earned interest to the DAO allowing stakers to deposit DAI or withdraw their stake in DAI. The contract buys cDAI and can transfer the daily interest to the DAO\"},\"userdoc\":{\"methods\":{\"renounceOwnership()\":{\"notice\":\"Renouncing to ownership will leave the contract without an owner. It will not be possible to call the functions with the `onlyOwner` modifier anymore.\"}}}},\"settings\":{\"compilationTarget\":{\"/Users/hadar/workspace/GoodDollar/GoodBootstrap/packages/contracts/stakingModel/contracts/SimpleDAIStaking.sol\":\"SimpleDAIStaking\"},\"evmVersion\":\"istanbul\",\"libraries\":{},\"optimizer\":{\"enabled\":true,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/hadar/workspace/GoodDollar/GoodBootstrap/packages/contracts/contracts/DSMath.sol\":{\"keccak256\":\"0x59fb5b1c4c3f68c1694f6ff5698016ac8ee9401b61e87473113dc103b7a6b0ff\",\"urls\":[\"bzz-raw://7410f43989dea44e64bed870958ce9199606dd8a9783e79fe8deca7b544164af\",\"dweb:/ipfs/QmPrrdvp2ErwL6SJSveB3JANo7ivadSMnk9gpWZD8nR7hy\"]},\"/Users/hadar/workspace/GoodDollar/GoodBootstrap/packages/contracts/contracts/dao/schemes/FeelessScheme.sol\":{\"keccak256\":\"0x7c542d44cbd864ee0ddecbc5016d9d7eb9ce65ab463fdd9f21eb8ce3c6ffc8ea\",\"urls\":[\"bzz-raw://4753dd823c0b0cbe7d7d02e1df64ace07d7a163af3aaff12697aee70a1b45f2f\",\"dweb:/ipfs/QmPkKeH88M3f6UbHphayUbjEBNV4rmoogtDmVundzBKbFK\"]},\"/Users/hadar/workspace/GoodDollar/GoodBootstrap/packages/contracts/contracts/dao/schemes/SchemeGuard.sol\":{\"keccak256\":\"0x32e1b2a172e2c22a6aa757bfcb0722cc67f64c5c2e48df3dec2737903516d565\",\"urls\":[\"bzz-raw://bee57a8eba08348e93a0c18f3ab534e67865c0fa27afe27f5cf234bd5f248915\",\"dweb:/ipfs/Qmd8aveHWcUkYWMyJrJRZPyVXj8MAMBfpBFo6g4Z2VJeo3\"]},\"/Users/hadar/workspace/GoodDollar/GoodBootstrap/packages/contracts/contracts/identity/Identity.sol\":{\"keccak256\":\"0x282184478f1d618d3523b28a84a7f7003dfdc99cad120e5e358d2cce1f5fb491\",\"urls\":[\"bzz-raw://67e17ecb57b24c4fb801abc2c52c3148af3b967e28da4fb7e074d18efb7a57c1\",\"dweb:/ipfs/QmfZ8jXhdTHtxr3gfByRj4HnXnGynX7SLZWWGR8k768aGB\"]},\"/Users/hadar/workspace/GoodDollar/GoodBootstrap/packages/contracts/contracts/identity/IdentityAdminRole.sol\":{\"keccak256\":\"0x8e82c45eefe0da77d017144dfad12602c68124297035937901cdd08ce48c57ff\",\"urls\":[\"bzz-raw://e20e606342b3b35f41a081294cf3f716fe7e27e81d3090daa37c5208f4ef4bc3\",\"dweb:/ipfs/QmVEhHpiwVsksnPyHkfNa5LpTBLxoP9kj5NRZUBv456ewK\"]},\"/Users/hadar/workspace/GoodDollar/GoodBootstrap/packages/contracts/contracts/identity/IdentityGuard.sol\":{\"keccak256\":\"0xcc395c0e8f812201b5ed1f45e7272120ee5ffe73bfe13e325dfd872aef235b22\",\"urls\":[\"bzz-raw://58f93e4b9f48ec31ac151208e4f9e6b356cc23dfc9585d846bc09bf35d6ff7be\",\"dweb:/ipfs/QmdxJHUCaFx8N66kkDhYdA4k6d2V91yBRG6sombuPxBq7X\"]},\"/Users/hadar/workspace/GoodDollar/GoodBootstrap/packages/contracts/stakingModel/contracts/SimpleDAIStaking.sol\":{\"keccak256\":\"0x245246632bb2a59a67277107f64975487806db57f8ad49d14e9626d8d72cd186\",\"urls\":[\"bzz-raw://e767763526d6b497514991f02db1a3da9c925ce32e522213f943cd2b8305cf12\",\"dweb:/ipfs/QmfUjN8Z59ZZNb3vkChmjoTGrpxwrNKNxzjML2pmrhWD2T\"]},\"@daostack/arc/contracts/controller/Avatar.sol\":{\"keccak256\":\"0x4e4fb9d3bc21f42fbfc6a01e9f8aa483a59e9f447b0d604f55b587a81ec09ef4\",\"urls\":[\"bzz-raw://9d3c1c7575cf6075ea1d89921f09b9b8e322b208dacaf0446cd4f64506c999f0\",\"dweb:/ipfs/QmVGDDHAR2ByuQpbgV7BBKXGEAcbaWvejpEZYzHgaagBFK\"]},\"@daostack/arc/contracts/controller/ControllerInterface.sol\":{\"keccak256\":\"0x933e92612c90f292c7b59908958b003f1a13d90b97bed0572b566353c20974dc\",\"urls\":[\"bzz-raw://ce1fcf85b744fcce2dbd4205e3943e9b4ec36a5f0330d4bbf61e65f1a3e0e470\",\"dweb:/ipfs/QmUWiLkBDdekhpy93nTzBtxDHL6yNh6sTUM9G8VbsHcBzy\"]},\"@daostack/arc/contracts/controller/DAOToken.sol\":{\"keccak256\":\"0x9b213e4e3ceeffcfc1c962a43b70b8d763d8091a2dd713fc1989b97bb68786e6\",\"urls\":[\"bzz-raw://51d1d6e85fd90f45395a16b7a3c703c4636e836041f2a13f806e4222ef2e59c1\",\"dweb:/ipfs/QmQjeCeFf7TJzsYjT5scyZUDDixBA8Yy8YppgBuxcKPDnP\"]},\"@daostack/arc/contracts/globalConstraints/GlobalConstraintInterface.sol\":{\"keccak256\":\"0xc006c4591ec10b845a56e13f6791db2c428610953034686d52b2a934b6c8f36f\",\"urls\":[\"bzz-raw://19495cd88280e54d7ddcd043ffeff75e6d3777a0c42debcd61cae448e9497ea0\",\"dweb:/ipfs/QmYxWz7CgFmmddrcVXJKfob5Ktwykc2imNVUwLSR5WR8bJ\"]},\"@daostack/arc/contracts/libs/SafeERC20.sol\":{\"keccak256\":\"0xf6727d432f67046145b078f40c1cc4f6be7b0d12a6678ecaf457edf7550d244c\",\"urls\":[\"bzz-raw://5dba7734c4fed446c084a707761cbc66ba22b8b93ef53c8d4a22a76b6e271690\",\"dweb:/ipfs/QmP2VpPKUqLh4ZZs6LaxHVpCN1zCmiorygL9bMub4mbYCw\"]},\"@daostack/infra/contracts/Reputation.sol\":{\"keccak256\":\"0x3d226dac0fe7d758f0287fb28bc25fcec1f69d19888ae3a550fa49856d61c482\",\"urls\":[\"bzz-raw://8856852c8fe0ba1c9aab326f0a9a6e7f31a238de2778fa5188e6fc399f7eb352\",\"dweb:/ipfs/QmVH4ppR9Dk7v8yxaSgeArdMv9gBBVoQxEf4E3UsqQ4rY2\"]},\"openzeppelin-solidity/contracts/access/Roles.sol\":{\"keccak256\":\"0x659ba0f9a3392cd50a8a5fafaf5dfd8c6a0878f6a4613bceff4e90dceddcd865\",\"urls\":[\"bzz-raw://4ca6617349a9b36fd82e9442a8e445ce9021a174e4399d1457ddc894ee3f5df3\",\"dweb:/ipfs/QmcmyB4cNazZ1sw963Afaijt67M9bDgwmGXCgQajGTD4tm\"]},\"openzeppelin-solidity/contracts/access/roles/PauserRole.sol\":{\"keccak256\":\"0x6506133e295a7199df2ac5dfc52853d9d767f68450b6d0193e9d8056b164ce86\",\"urls\":[\"bzz-raw://9c03592a9e6b1377e401b74eccf175a250232b5a341347d3fc5cb50e9bc86ba2\",\"dweb:/ipfs/QmYAr1yXT89hNUMJ37aiBpD9HtYfBDqmueVCzphRuuU7oZ\"]},\"openzeppelin-solidity/contracts/lifecycle/Pausable.sol\":{\"keccak256\":\"0x3b0ed31deeba7e3c6cfbbe8092a6b427084ee390800a06acdea5c17c8185d606\",\"urls\":[\"bzz-raw://bbdbf9d3754fcdcc85aec0432fabcec914317b1c2081b43753442ed53853a34a\",\"dweb:/ipfs/QmVHWQBn5xQkQEHhyGNEeS5gjjALZEk5ZfcjFt7kL6MoLy\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x965012d27b4262d7a41f5028cbb30c51ebd9ecd4be8fb30380aaa7a3c64fbc8b\",\"urls\":[\"bzz-raw://1eb493553b27efd46c231a836a83ce50d215639feb97b4aac9f301d0fd034ff5\",\"dweb:/ipfs/QmbMdvSXcqGKxeeYvzF3VrWpoHQyVzMXBhzhAokF2Gdymv\"]},\"openzeppelin-solidity/contracts/ownership/Ownable.sol\":{\"keccak256\":\"0x980de387a1a020a498f53d00f89fecebb12c949a17e8f160093c0303ede2b786\",\"urls\":[\"bzz-raw://f07a2c393caa85f62f0aaa461e3edd50aa59371d4209778ba0558d7f8b4b856c\",\"dweb:/ipfs/QmeN3ZiYGSjCnQFeYaJNgoXjF9eDue1g3e9pqManRkeBtV\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0xba431353cb4fe70777ac026231eb5468e41aa1e81240a2b8136917acc5fff4dc\",\"urls\":[\"bzz-raw://f40c91ca270bdc9b156f339081a0fc2bbcf73cf5f62b8c73ba555df753ff6619\",\"dweb:/ipfs/QmT8y2VVjGaFdGphpcXrgvdPi2EgF9LuCDgJiJ89LvpFRV\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20Burnable.sol\":{\"keccak256\":\"0xa3e68fd7f987c8fbdaf4867d428a69a15f3cf2f69709a5b0a0fbef750b0e6fbc\",\"urls\":[\"bzz-raw://50b1ff986d3b2793850a66c8429d9886fdfb134b1509b3e98714e3e2a71e24f5\",\"dweb:/ipfs/QmSQBYPeY9tbR3ciGRNQqvcWKnNiuxtVMq2MsPWpLwuGGm\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0x079c4e23ee448f529e43bfa3c4e8fb4be52cd0318ee923a276835bedf45b93d8\",\"urls\":[\"bzz-raw://ee762ff5b7746e41d27dcbcea00c7a3034b58adb1b45ddadddb5b721aff450df\",\"dweb:/ipfs/QmdxqtgEFZjHCoiYyz6pUAQ5iBm7As25jcyEbZoTaAgyDa\"]},\"openzeppelin-solidity/contracts/utils/Address.sol\":{\"keccak256\":\"0x5c731061b804fa256fc8c05150eafe5d20b6bb94541a8f187912bf84f7033f34\",\"urls\":[\"bzz-raw://a3c2d9f046beebab7fb41b1b124a6a124a36f510f7c67365861402ac831bdc71\",\"dweb:/ipfs/QmUtASRgitregbKH83anopLtF9vFQe3BKeAjhUa6F7t9YV\"]}},\"version\":1}",
  "bytecode": "0x6080604052600380546001600160a01b03191690556000600a55600b805463ffffffff1916620f42401790553480156200003857600080fd5b50604051620025a3380380620025a3833981810160405260c08110156200005e57600080fd5b508051602082015160408301516060840151608085015160a0909501519394929391929091808281816200009b336001600160e01b03620002bf16565b600180546001600160a81b03191661010033810291909117918290556040516001600160a01b039190920416906000907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908290a3600280546001600160a01b0319166001600160a01b0383811691909117918290551615620001b557600260009054906101000a90046001600160a01b03166001600160a01b0316638da5cb5b6040518163ffffffff1660e01b815260040160206040518083038186803b1580156200016757600080fd5b505afa1580156200017c573d6000803e3d6000fd5b505050506040513d60208110156200019357600080fd5b5051600380546001600160a01b0319166001600160a01b039092169190911790555b506001600160a01b03811662000212576040805162461bcd60e51b815260206004820152601960248201527f537570706c696564206964656e74697479206973206e756c6c00000000000000604482015290519081900360640190fd5b600480546001600160a01b03199081166001600160a01b03938416179091556006805482168b841617905560078054909116918916919091179055505060088390556200026c438462000311602090811b6200187217901c565b600955600b80546001600160a01b0380871664010000000002600160201b600160c01b031990921691909117909155600254620002b391166001600160e01b036200033516565b5050505050506200041c565b620002da8160006200036a60201b62001fce1790919060201c565b6040516001600160a01b038216907f6719d08c1888103bea251a4ed56406bd0c3e69723c8a1686e017e7bbe159b6f890600090a250565b60008082116200032057600080fd5b60008284816200032c57fe5b04949350505050565b62000349336001600160e01b03620003c316565b6200035357600080fd5b62000367816001600160e01b03620002bf16565b50565b6001600160a01b0381166200037e57600080fd5b6200039382826001600160e01b03620003e616565b156200039e57600080fd5b6001600160a01b0316600090815260209190915260409020805460ff19166001179055565b6000620003e0826000620003e660201b620018c41790919060201c565b92915050565b60006001600160a01b038216620003fc57600080fd5b506001600160a01b03166000908152602091909152604090205460ff1690565b612177806200042c6000396000f3fe608060405234801561001057600080fd5b50600436106101fb5760003560e01c8063817b1cd21161011a578063be9a6555116100ad578063c9b0d97b1161007c578063c9b0d97b146104aa578063e8b2467d146104b2578063efbe1c1c146104d3578063f2fde38b146104db578063f4b9fa7514610501576101fb565b8063be9a65551461046c578063bed9d86114610474578063c3c5a5471461047c578063c4c22e98146104a2576101fb565b80638da5cb5b116100e95780638da5cb5b146104155780638f32d59b1461041d5780639168ae72146104255780639b089d5514610464576101fb565b8063817b1cd2146103d75780638247cc0c146103df57806382dc1ec4146103e75780638456cb591461040d576101fb565b80633f4ba83a116101925780636209ec2d116101615780636209ec2d146103a257806364aab239146103aa5780636ef8d66d146103c7578063715018a6146103cf576101fb565b80633f4ba83a1461034657806346fbf68e1461034e5780635c975abb146103745780635d5bf1781461037c576101fb565b806322366844116101ce578063223668441461028e578063232a3060146102aa5780632c159a1a146102d057806337455990146102f4576101fb565b8063086cfca8146102005780630cd865ec1461022857806317e49ca11461024e578063210a27a914610274575b600080fd5b6102266004803603602081101561021657600080fd5b50356001600160a01b0316610509565b005b6102266004803603602081101561023e57600080fd5b50356001600160a01b03166105c4565b6102566107d7565b60408051938452602084019290925282820152519081900360600190f35b61027c610925565b60408051918252519081900360200190f35b610296610a4e565b604080519115158252519081900360200190f35b610226600480360360208110156102c057600080fd5b50356001600160a01b0316610a5e565b6102d8610aeb565b604080516001600160a01b039092168252519081900360200190f35b61031a6004803603602081101561030a57600080fd5b50356001600160a01b0316610afa565b6040805194855260208501939093528383019190915263ffffffff166060830152519081900360800190f35b610226610d5d565b6102966004803603602081101561036457600080fd5b50356001600160a01b0316610dbd565b610296610dd7565b6102266004803603602081101561039257600080fd5b50356001600160a01b0316610de0565b6102d8610ec9565b610226600480360360208110156103c057600080fd5b5035610ee0565b6102266111b2565b6102266111bd565b61027c61121e565b61027c611224565b610226600480360360208110156103fd57600080fd5b50356001600160a01b031661122a565b610226611248565b6102d86112ab565b6102966112bf565b61044b6004803603602081101561043b57600080fd5b50356001600160a01b03166112d5565b6040805192835260208301919091528051918290030190f35b6102d86112ee565b6102266112fd565b610226611359565b6102966004803603602081101561049257600080fd5b50356001600160a01b0316611622565b61027c61170e565b610296611714565b6104ba611734565b6040805163ffffffff9092168252519081900360200190f35b610226611740565b610226600480360360208110156104f157600080fd5b50356001600160a01b03166117af565b6102d86117c9565b6105116112bf565b61051a57600080fd5b600280546001600160a01b0319166001600160a01b03838116919091179182905560408051638da5cb5b60e01b815290519290911691638da5cb5b91600480820192602092909190829003018186803b15801561057657600080fd5b505afa15801561058a573d6000803e3d6000fd5b505050506040513d60208110156105a057600080fd5b5051600380546001600160a01b0319166001600160a01b0390921691909117905550565b6002546001600160a01b03163314610623576040805162461bcd60e51b815260206004820181905260248201527f6f6e6c79204176617461722063616e2063616c6c2074686973206d6574686f64604482015290519081900360640190fd5b604080516370a0823160e01b815230600482015290516000916001600160a01b038416916370a0823191602480820192602092909190829003018186803b15801561066d57600080fd5b505afa158015610681573d6000803e3d6000fd5b505050506040513d602081101561069757600080fd5b50516007549091506001600160a01b038381169116141561070057600a541580156106c557506106c5610dd7565b6107005760405162461bcd60e51b81526004018080602001828103825260358152602001806120446035913960400191505060405180910390fd5b6002546040805163a9059cbb60e01b81526001600160a01b0392831660048201526024810184905290519184169163a9059cbb916044808201926020929091908290030181600087803b15801561075657600080fd5b505af115801561076a573d6000803e3d6000fd5b505050506040513d602081101561078057600080fd5b50516107d3576040805162461bcd60e51b815260206004820152601760248201527f7265636f766572207472616e73666572206661696c6564000000000000000000604482015290519081900360640190fd5b5050565b600080600080600760009054906101000a90046001600160a01b03166001600160a01b031663182df0f56040518163ffffffff1660e01b815260040160206040518083038186803b15801561082b57600080fd5b505afa15801561083f573d6000803e3d6000fd5b505050506040513d602081101561085557600080fd5b505190506000610863610925565b9050600a5481116108805750600093508392508291506109209050565b6000610897600a54836117d890919063ffffffff16565b905060006108b96108b3836402540be40063ffffffff6117f216565b85611820565b905060006108d582678ac7230489e8000063ffffffff61185516565b90506108ef82678ac7230489e8000063ffffffff61187216565b915060006109126402540be4006109068489611894565b9063ffffffff61187216565b929850929650909450505050505b909192565b600080600760009054906101000a90046001600160a01b03166001600160a01b031663182df0f56040518163ffffffff1660e01b815260040160206040518083038186803b15801561097657600080fd5b505afa15801561098a573d6000803e3d6000fd5b505050506040513d60208110156109a057600080fd5b5051600754604080516370a0823160e01b81523060048201529051929350600092610a4792600a9261090692610a41926402540be400926001600160a01b03909116916370a0823191602480820192602092909190829003018186803b158015610a0957600080fd5b505afa158015610a1d573d6000803e3d6000fd5b505050506040513d6020811015610a3357600080fd5b50519063ffffffff6117f216565b85611894565b9250505090565b6000610a5930611622565b905090565b6002546001600160a01b03163314610abd576040805162461bcd60e51b815260206004820181905260248201527f6f6e6c79204176617461722063616e2063616c6c2074686973206d6574686f64604482015290519081900360640190fd5b600b80546001600160a01b0390921664010000000002640100000000600160c01b0319909216919091179055565b6004546001600160a01b031681565b600080600080600b60049054906101000a90046001600160a01b03166001600160a01b0316336001600160a01b031614610b655760405162461bcd60e51b81526004018080602001828103825260258152602001806120796025913960400191505060405180910390fd5b6001600160a01b038516301415610bad5760405162461bcd60e51b81526004018080602001828103825260288152602001806120c16028913960400191505060405180910390fd5b610bb5611714565b610bf05760405162461bcd60e51b81526004018080602001828103825260228152602001806120e96022913960400191505060405180910390fd5b6000806000610bfd6107d7565b925092509250610c186008544361187290919063ffffffff16565b6009558215610cf4576007546040805163a9059cbb60e01b81526001600160a01b038b81166004830152602482018790529151919092169163a9059cbb9160448083019260209291908290030181600087803b158015610c7757600080fd5b505af1158015610c8b573d6000803e3d6000fd5b505050506040513d6020811015610ca157600080fd5b5051610cf4576040805162461bcd60e51b815260206004820152601760248201527f636f6c6c656374207472616e73666572206661696c6564000000000000000000604482015290519081900360640190fd5b604080516001600160a01b038a168152602081018590528082018490526060810183905290517f0abcfa9ece819bcdcfa052a818ce11f0b9fad8b3e3ccd98f120c40be689b690f9181900360800190a1600b549298919750955063ffffffff9091169350915050565b610d6633610dbd565b610d6f57600080fd5b60015460ff16610d7e57600080fd5b6001805460ff191690556040805133815290517f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa9181900360200190a1565b6000610dcf818363ffffffff6118c416565b90505b919050565b60015460ff1690565b610de86112bf565b610df157600080fd5b806001600160a01b031663223668446040518163ffffffff1660e01b815260040160206040518083038186803b158015610e2a57600080fd5b505afa158015610e3e573d6000803e3d6000fd5b505050506040513d6020811015610e5457600080fd5b5051610ea7576040805162461bcd60e51b815260206004820152601a60248201527f4964656e74697479206973206e6f742072656769737465726564000000000000604482015290519081900360640190fd5b600480546001600160a01b0319166001600160a01b0392909216919091179055565b600b5464010000000090046001600160a01b031681565b60015460ff1615610ef057600080fd5b60008111610f2f5760405162461bcd60e51b815260040180806020018281038252602981526020018061201b6029913960400191505060405180910390fd5b600654604080516323b872dd60e01b81523360048201523060248201526044810184905290516001600160a01b03909216916323b872dd916064808201926020929091908290030181600087803b158015610f8957600080fd5b505af1158015610f9d573d6000803e3d6000fd5b505050506040513d6020811015610fb357600080fd5b50511515600114610ff55760405162461bcd60e51b815260040180806020018281038252603881526020018061210b6038913960400191505060405180910390fd5b6006546007546040805163095ea7b360e01b81526001600160a01b039283166004820152602481018590529051919092169163095ea7b39160448083019260209291908290030181600087803b15801561104e57600080fd5b505af1158015611062573d6000803e3d6000fd5b505050506040513d602081101561107857600080fd5b50506007546040805163140e25ad60e31b81526004810184905290516000926001600160a01b03169163a0712d6891602480830192602092919082900301818787803b1580156110c757600080fd5b505af11580156110db573d6000803e3d6000fd5b505050506040513d60208110156110f157600080fd5b5051905080156111385780156111385760405162461bcd60e51b815260040180806020018281038252602381526020018061209e6023913960400191505060405180910390fd5b3360009081526005602052604090208054611159908463ffffffff6118f916565b8155436001820155600a54611174908463ffffffff6118f916565b600a5560408051848152905133917f39f13ee9b63dd3ac2e710600c086583db75aed574725071a694419f706d17244919081900360200190a2505050565b6111bb3361190b565b565b6111c56112bf565b6111ce57600080fd5b60015460405160009161010090046001600160a01b0316907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a360018054610100600160a81b0319169055565b600a5481565b60095481565b61123333610dbd565b61123c57600080fd5b61124581611953565b50565b61125133610dbd565b61125a57600080fd5b60015460ff161561126a57600080fd5b6001805460ff1916811790556040805133815290517f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2589181900360200190a1565b60015461010090046001600160a01b031690565b60015461010090046001600160a01b0316331490565b6005602052600090815260409020805460019091015482565b6007546001600160a01b031681565b611305610a4e565b611351576040805162461bcd60e51b815260206004820152601860248201527714d8da195b59481a5cc81b9bdd081c9959da5cdd195c995960421b604482015290519081900360640190fd5b6111bb61199b565b33600090815260056020526040902080546113ab576040805162461bcd60e51b815260206004820152600d60248201526c139bc8111052481cdd185ad959609a1b604482015290519081900360640190fd5b60075481546040805163852a12e360e01b81526004810192909252516001600160a01b039092169163852a12e3916024808201926020929091908290030181600087803b1580156113fb57600080fd5b505af115801561140f573d6000803e3d6000fd5b505050506040513d602081101561142557600080fd5b505115611471576040805162461bcd60e51b81526020600482015260156024820152744661696c656420746f2072656465656d206344616960581b604482015290519081900360640190fd5b805460008255600a5461148a908263ffffffff6117d816565b600a55600654604080516370a0823160e01b815230600482015290516000926001600160a01b0316916370a08231916024808301926020929190829003018186803b1580156114d857600080fd5b505afa1580156114ec573d6000803e3d6000fd5b505050506040513d602081101561150257600080fd5b5051905081811015611512578091505b6006546040805163a9059cbb60e01b81523360048201526024810185905290516001600160a01b039092169163a9059cbb916044808201926020929091908290030181600087803b15801561156657600080fd5b505af115801561157a573d6000803e3d6000fd5b505050506040513d602081101561159057600080fd5b50516115e3576040805162461bcd60e51b815260206004820152601860248201527f7769746864726177207472616e73666572206661696c65640000000000000000604482015290519081900360640190fd5b6040805183815260208101839052815133927f7441c5625c09ad27ec4eec0984408b247a5ec0cbb33cb619115a4551f71798e7928290030190a2505050565b6002546000906001600160a01b0316611676576040805162461bcd60e51b8152602060048201526011602482015270105d985d185c881a5cc81b9bdd081cd95d607a1b604482015290519081900360640190fd5b60035460025460408051639be2faed60e01b81526001600160a01b038681166004830152928316602482015290519190921691639be2faed916044808301926020929190829003018186803b1580156116ce57600080fd5b505afa1580156116e2573d6000803e3d6000fd5b505050506040513d60208110156116f857600080fd5b505161170657506000610dd2565b506001919050565b60085481565b600060095461172e6008544361187290919063ffffffff16565b11905090565b600b5463ffffffff1681565b6002546001600160a01b0316331461179f576040805162461bcd60e51b815260206004820181905260248201527f6f6e6c79204176617461722063616e2063616c6c2074686973206d6574686f64604482015290519081900360640190fd5b6117a7611248565b6111bb611c05565b6117b76112bf565b6117c057600080fd5b61124581611e5a565b6006546001600160a01b031681565b6000828211156117e757600080fd5b508082035b92915050565b600082611801575060006117ec565b8282028284828161180e57fe5b041461181957600080fd5b9392505050565b60008161184661183c856b033b2e3c9fd0803ce8000000611ed4565b6002855b04611f37565b8161184d57fe5b049392505050565b60008161186157600080fd5b81838161186a57fe5b069392505050565b600080821161188057600080fd5b600082848161188b57fe5b04949350505050565b60006b033b2e3c9fd0803ce80000006118466118b08585611ed4565b60026b033b2e3c9fd0803ce8000000611840565b60006001600160a01b0382166118d957600080fd5b506001600160a01b03166000908152602091909152604090205460ff1690565b60008282018381101561181957600080fd5b61191c60008263ffffffff611f8616565b6040516001600160a01b038216907fcd265ebaf09df2871cc7bd4133404a235ba12eff2041bb89d9c714a2621c7c7e90600090a250565b61196460008263ffffffff611fce16565b6040516001600160a01b038216907f6719d08c1888103bea251a4ed56406bd0c3e69723c8a1686e017e7bbe159b6f890600090a250565b6119a3610a4e565b6119ef576040805162461bcd60e51b815260206004820152601860248201527714d8da195b59481a5cc81b9bdd081c9959da5cdd195c995960421b604482015290519081900360640190fd5b600354600480546040805130602480830191909152825180830382018152604492830184526020810180516001600160e01b0316635f539d6960e01b17815260025494516368db844d60e11b81526001600160a01b039687169781018881529587169481018590526000606482018190526080948201948552835160848301528351979099169863d1b7089a9897939690949093909260a49092019190808383885b83811015611aa9578181015183820152602001611a91565b50505050905090810190601f168015611ad65780820380516001836020036101000a031916815260200191505b5095505050505050600060405180830381600087803b158015611af857600080fd5b505af1158015611b0c573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040908152811015611b3557600080fd5b815160208301805160405192949293830192919084640100000000821115611b5c57600080fd5b908301906020820185811115611b7157600080fd5b8251640100000000811182820188101715611b8b57600080fd5b82525081516020918201929091019080838360005b83811015611bb8578181015183820152602001611ba0565b50505050905090810190601f168015611be55780820380516001836020036101000a031916815260200191505b5060405250506002546111bb93506001600160a01b031691506117af9050565b611c0d610a4e565b611c59576040805162461bcd60e51b815260206004820152601860248201527714d8da195b59481a5cc81b9bdd081c9959da5cdd195c995960421b604482015290519081900360640190fd5b600354600480546040805130602480830191909152825180830382018152604492830184526020810180516001600160e01b031663c375c2ef60e01b17815260025494516368db844d60e11b81526001600160a01b039687169781018881529587169481018590526000606482018190526080948201948552835160848301528351979099169863d1b7089a9897939690949093909260a49092019190808383885b83811015611d13578181015183820152602001611cfb565b50505050905090810190601f168015611d405780820380516001836020036101000a031916815260200191505b5095505050505050600060405180830381600087803b158015611d6257600080fd5b505af1158015611d76573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040908152811015611d9f57600080fd5b815160208301805160405192949293830192919084640100000000821115611dc657600080fd5b908301906020820185811115611ddb57600080fd5b8251640100000000811182820188101715611df557600080fd5b82525081516020918201929091019080838360005b83811015611e22578181015183820152602001611e0a565b50505050905090810190601f168015611e4f5780820380516001836020036101000a031916815260200191505b506040525050505050565b6001600160a01b038116611e6d57600080fd5b6001546040516001600160a01b0380841692610100900416907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a3600180546001600160a01b0390921661010002610100600160a81b0319909216919091179055565b6000811580611eef57505080820282828281611eec57fe5b04145b6117ec576040805162461bcd60e51b815260206004820152601460248201527364732d6d6174682d6d756c2d6f766572666c6f7760601b604482015290519081900360640190fd5b808201828110156117ec576040805162461bcd60e51b815260206004820152601460248201527364732d6d6174682d6164642d6f766572666c6f7760601b604482015290519081900360640190fd5b6001600160a01b038116611f9957600080fd5b611fa382826118c4565b611fac57600080fd5b6001600160a01b0316600090815260209190915260409020805460ff19169055565b6001600160a01b038116611fe157600080fd5b611feb82826118c4565b15611ff557600080fd5b6001600160a01b0316600090815260209190915260409020805460ff1916600117905556fe596f75206e65656420746f207374616b65206120706f73697469766520746f6b656e20616d6f756e7463616e207265636f7665722063446169206f6e6c79207768656e207374616b65732068617665206265656e2077697468647261776e4f6e6c792046756e644d616e616765722063616e2063616c6c2074686973206d6574686f644d696e74696e672063446169206661696c65642c2066756e64732072657475726e6564526563697069656e742063616e6e6f7420626520746865207374616b696e6720636f6e74726163744e65656420746f207761697420666f7220746865206e65787420696e74657276616c7472616e7366657246726f6d206661696c65642c206d616b65207375726520796f7520617070726f76656420444149207472616e73666572a265627a7a723158208c8b260f403aa9f875b4927de2b87ac43fc28a609654fac761f86260fafcf8e264736f6c63430005100032",
  "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106101fb5760003560e01c8063817b1cd21161011a578063be9a6555116100ad578063c9b0d97b1161007c578063c9b0d97b146104aa578063e8b2467d146104b2578063efbe1c1c146104d3578063f2fde38b146104db578063f4b9fa7514610501576101fb565b8063be9a65551461046c578063bed9d86114610474578063c3c5a5471461047c578063c4c22e98146104a2576101fb565b80638da5cb5b116100e95780638da5cb5b146104155780638f32d59b1461041d5780639168ae72146104255780639b089d5514610464576101fb565b8063817b1cd2146103d75780638247cc0c146103df57806382dc1ec4146103e75780638456cb591461040d576101fb565b80633f4ba83a116101925780636209ec2d116101615780636209ec2d146103a257806364aab239146103aa5780636ef8d66d146103c7578063715018a6146103cf576101fb565b80633f4ba83a1461034657806346fbf68e1461034e5780635c975abb146103745780635d5bf1781461037c576101fb565b806322366844116101ce578063223668441461028e578063232a3060146102aa5780632c159a1a146102d057806337455990146102f4576101fb565b8063086cfca8146102005780630cd865ec1461022857806317e49ca11461024e578063210a27a914610274575b600080fd5b6102266004803603602081101561021657600080fd5b50356001600160a01b0316610509565b005b6102266004803603602081101561023e57600080fd5b50356001600160a01b03166105c4565b6102566107d7565b60408051938452602084019290925282820152519081900360600190f35b61027c610925565b60408051918252519081900360200190f35b610296610a4e565b604080519115158252519081900360200190f35b610226600480360360208110156102c057600080fd5b50356001600160a01b0316610a5e565b6102d8610aeb565b604080516001600160a01b039092168252519081900360200190f35b61031a6004803603602081101561030a57600080fd5b50356001600160a01b0316610afa565b6040805194855260208501939093528383019190915263ffffffff166060830152519081900360800190f35b610226610d5d565b6102966004803603602081101561036457600080fd5b50356001600160a01b0316610dbd565b610296610dd7565b6102266004803603602081101561039257600080fd5b50356001600160a01b0316610de0565b6102d8610ec9565b610226600480360360208110156103c057600080fd5b5035610ee0565b6102266111b2565b6102266111bd565b61027c61121e565b61027c611224565b610226600480360360208110156103fd57600080fd5b50356001600160a01b031661122a565b610226611248565b6102d86112ab565b6102966112bf565b61044b6004803603602081101561043b57600080fd5b50356001600160a01b03166112d5565b6040805192835260208301919091528051918290030190f35b6102d86112ee565b6102266112fd565b610226611359565b6102966004803603602081101561049257600080fd5b50356001600160a01b0316611622565b61027c61170e565b610296611714565b6104ba611734565b6040805163ffffffff9092168252519081900360200190f35b610226611740565b610226600480360360208110156104f157600080fd5b50356001600160a01b03166117af565b6102d86117c9565b6105116112bf565b61051a57600080fd5b600280546001600160a01b0319166001600160a01b03838116919091179182905560408051638da5cb5b60e01b815290519290911691638da5cb5b91600480820192602092909190829003018186803b15801561057657600080fd5b505afa15801561058a573d6000803e3d6000fd5b505050506040513d60208110156105a057600080fd5b5051600380546001600160a01b0319166001600160a01b0390921691909117905550565b6002546001600160a01b03163314610623576040805162461bcd60e51b815260206004820181905260248201527f6f6e6c79204176617461722063616e2063616c6c2074686973206d6574686f64604482015290519081900360640190fd5b604080516370a0823160e01b815230600482015290516000916001600160a01b038416916370a0823191602480820192602092909190829003018186803b15801561066d57600080fd5b505afa158015610681573d6000803e3d6000fd5b505050506040513d602081101561069757600080fd5b50516007549091506001600160a01b038381169116141561070057600a541580156106c557506106c5610dd7565b6107005760405162461bcd60e51b81526004018080602001828103825260358152602001806120446035913960400191505060405180910390fd5b6002546040805163a9059cbb60e01b81526001600160a01b0392831660048201526024810184905290519184169163a9059cbb916044808201926020929091908290030181600087803b15801561075657600080fd5b505af115801561076a573d6000803e3d6000fd5b505050506040513d602081101561078057600080fd5b50516107d3576040805162461bcd60e51b815260206004820152601760248201527f7265636f766572207472616e73666572206661696c6564000000000000000000604482015290519081900360640190fd5b5050565b600080600080600760009054906101000a90046001600160a01b03166001600160a01b031663182df0f56040518163ffffffff1660e01b815260040160206040518083038186803b15801561082b57600080fd5b505afa15801561083f573d6000803e3d6000fd5b505050506040513d602081101561085557600080fd5b505190506000610863610925565b9050600a5481116108805750600093508392508291506109209050565b6000610897600a54836117d890919063ffffffff16565b905060006108b96108b3836402540be40063ffffffff6117f216565b85611820565b905060006108d582678ac7230489e8000063ffffffff61185516565b90506108ef82678ac7230489e8000063ffffffff61187216565b915060006109126402540be4006109068489611894565b9063ffffffff61187216565b929850929650909450505050505b909192565b600080600760009054906101000a90046001600160a01b03166001600160a01b031663182df0f56040518163ffffffff1660e01b815260040160206040518083038186803b15801561097657600080fd5b505afa15801561098a573d6000803e3d6000fd5b505050506040513d60208110156109a057600080fd5b5051600754604080516370a0823160e01b81523060048201529051929350600092610a4792600a9261090692610a41926402540be400926001600160a01b03909116916370a0823191602480820192602092909190829003018186803b158015610a0957600080fd5b505afa158015610a1d573d6000803e3d6000fd5b505050506040513d6020811015610a3357600080fd5b50519063ffffffff6117f216565b85611894565b9250505090565b6000610a5930611622565b905090565b6002546001600160a01b03163314610abd576040805162461bcd60e51b815260206004820181905260248201527f6f6e6c79204176617461722063616e2063616c6c2074686973206d6574686f64604482015290519081900360640190fd5b600b80546001600160a01b0390921664010000000002640100000000600160c01b0319909216919091179055565b6004546001600160a01b031681565b600080600080600b60049054906101000a90046001600160a01b03166001600160a01b0316336001600160a01b031614610b655760405162461bcd60e51b81526004018080602001828103825260258152602001806120796025913960400191505060405180910390fd5b6001600160a01b038516301415610bad5760405162461bcd60e51b81526004018080602001828103825260288152602001806120c16028913960400191505060405180910390fd5b610bb5611714565b610bf05760405162461bcd60e51b81526004018080602001828103825260228152602001806120e96022913960400191505060405180910390fd5b6000806000610bfd6107d7565b925092509250610c186008544361187290919063ffffffff16565b6009558215610cf4576007546040805163a9059cbb60e01b81526001600160a01b038b81166004830152602482018790529151919092169163a9059cbb9160448083019260209291908290030181600087803b158015610c7757600080fd5b505af1158015610c8b573d6000803e3d6000fd5b505050506040513d6020811015610ca157600080fd5b5051610cf4576040805162461bcd60e51b815260206004820152601760248201527f636f6c6c656374207472616e73666572206661696c6564000000000000000000604482015290519081900360640190fd5b604080516001600160a01b038a168152602081018590528082018490526060810183905290517f0abcfa9ece819bcdcfa052a818ce11f0b9fad8b3e3ccd98f120c40be689b690f9181900360800190a1600b549298919750955063ffffffff9091169350915050565b610d6633610dbd565b610d6f57600080fd5b60015460ff16610d7e57600080fd5b6001805460ff191690556040805133815290517f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa9181900360200190a1565b6000610dcf818363ffffffff6118c416565b90505b919050565b60015460ff1690565b610de86112bf565b610df157600080fd5b806001600160a01b031663223668446040518163ffffffff1660e01b815260040160206040518083038186803b158015610e2a57600080fd5b505afa158015610e3e573d6000803e3d6000fd5b505050506040513d6020811015610e5457600080fd5b5051610ea7576040805162461bcd60e51b815260206004820152601a60248201527f4964656e74697479206973206e6f742072656769737465726564000000000000604482015290519081900360640190fd5b600480546001600160a01b0319166001600160a01b0392909216919091179055565b600b5464010000000090046001600160a01b031681565b60015460ff1615610ef057600080fd5b60008111610f2f5760405162461bcd60e51b815260040180806020018281038252602981526020018061201b6029913960400191505060405180910390fd5b600654604080516323b872dd60e01b81523360048201523060248201526044810184905290516001600160a01b03909216916323b872dd916064808201926020929091908290030181600087803b158015610f8957600080fd5b505af1158015610f9d573d6000803e3d6000fd5b505050506040513d6020811015610fb357600080fd5b50511515600114610ff55760405162461bcd60e51b815260040180806020018281038252603881526020018061210b6038913960400191505060405180910390fd5b6006546007546040805163095ea7b360e01b81526001600160a01b039283166004820152602481018590529051919092169163095ea7b39160448083019260209291908290030181600087803b15801561104e57600080fd5b505af1158015611062573d6000803e3d6000fd5b505050506040513d602081101561107857600080fd5b50506007546040805163140e25ad60e31b81526004810184905290516000926001600160a01b03169163a0712d6891602480830192602092919082900301818787803b1580156110c757600080fd5b505af11580156110db573d6000803e3d6000fd5b505050506040513d60208110156110f157600080fd5b5051905080156111385780156111385760405162461bcd60e51b815260040180806020018281038252602381526020018061209e6023913960400191505060405180910390fd5b3360009081526005602052604090208054611159908463ffffffff6118f916565b8155436001820155600a54611174908463ffffffff6118f916565b600a5560408051848152905133917f39f13ee9b63dd3ac2e710600c086583db75aed574725071a694419f706d17244919081900360200190a2505050565b6111bb3361190b565b565b6111c56112bf565b6111ce57600080fd5b60015460405160009161010090046001600160a01b0316907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a360018054610100600160a81b0319169055565b600a5481565b60095481565b61123333610dbd565b61123c57600080fd5b61124581611953565b50565b61125133610dbd565b61125a57600080fd5b60015460ff161561126a57600080fd5b6001805460ff1916811790556040805133815290517f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2589181900360200190a1565b60015461010090046001600160a01b031690565b60015461010090046001600160a01b0316331490565b6005602052600090815260409020805460019091015482565b6007546001600160a01b031681565b611305610a4e565b611351576040805162461bcd60e51b815260206004820152601860248201527714d8da195b59481a5cc81b9bdd081c9959da5cdd195c995960421b604482015290519081900360640190fd5b6111bb61199b565b33600090815260056020526040902080546113ab576040805162461bcd60e51b815260206004820152600d60248201526c139bc8111052481cdd185ad959609a1b604482015290519081900360640190fd5b60075481546040805163852a12e360e01b81526004810192909252516001600160a01b039092169163852a12e3916024808201926020929091908290030181600087803b1580156113fb57600080fd5b505af115801561140f573d6000803e3d6000fd5b505050506040513d602081101561142557600080fd5b505115611471576040805162461bcd60e51b81526020600482015260156024820152744661696c656420746f2072656465656d206344616960581b604482015290519081900360640190fd5b805460008255600a5461148a908263ffffffff6117d816565b600a55600654604080516370a0823160e01b815230600482015290516000926001600160a01b0316916370a08231916024808301926020929190829003018186803b1580156114d857600080fd5b505afa1580156114ec573d6000803e3d6000fd5b505050506040513d602081101561150257600080fd5b5051905081811015611512578091505b6006546040805163a9059cbb60e01b81523360048201526024810185905290516001600160a01b039092169163a9059cbb916044808201926020929091908290030181600087803b15801561156657600080fd5b505af115801561157a573d6000803e3d6000fd5b505050506040513d602081101561159057600080fd5b50516115e3576040805162461bcd60e51b815260206004820152601860248201527f7769746864726177207472616e73666572206661696c65640000000000000000604482015290519081900360640190fd5b6040805183815260208101839052815133927f7441c5625c09ad27ec4eec0984408b247a5ec0cbb33cb619115a4551f71798e7928290030190a2505050565b6002546000906001600160a01b0316611676576040805162461bcd60e51b8152602060048201526011602482015270105d985d185c881a5cc81b9bdd081cd95d607a1b604482015290519081900360640190fd5b60035460025460408051639be2faed60e01b81526001600160a01b038681166004830152928316602482015290519190921691639be2faed916044808301926020929190829003018186803b1580156116ce57600080fd5b505afa1580156116e2573d6000803e3d6000fd5b505050506040513d60208110156116f857600080fd5b505161170657506000610dd2565b506001919050565b60085481565b600060095461172e6008544361187290919063ffffffff16565b11905090565b600b5463ffffffff1681565b6002546001600160a01b0316331461179f576040805162461bcd60e51b815260206004820181905260248201527f6f6e6c79204176617461722063616e2063616c6c2074686973206d6574686f64604482015290519081900360640190fd5b6117a7611248565b6111bb611c05565b6117b76112bf565b6117c057600080fd5b61124581611e5a565b6006546001600160a01b031681565b6000828211156117e757600080fd5b508082035b92915050565b600082611801575060006117ec565b8282028284828161180e57fe5b041461181957600080fd5b9392505050565b60008161184661183c856b033b2e3c9fd0803ce8000000611ed4565b6002855b04611f37565b8161184d57fe5b049392505050565b60008161186157600080fd5b81838161186a57fe5b069392505050565b600080821161188057600080fd5b600082848161188b57fe5b04949350505050565b60006b033b2e3c9fd0803ce80000006118466118b08585611ed4565b60026b033b2e3c9fd0803ce8000000611840565b60006001600160a01b0382166118d957600080fd5b506001600160a01b03166000908152602091909152604090205460ff1690565b60008282018381101561181957600080fd5b61191c60008263ffffffff611f8616565b6040516001600160a01b038216907fcd265ebaf09df2871cc7bd4133404a235ba12eff2041bb89d9c714a2621c7c7e90600090a250565b61196460008263ffffffff611fce16565b6040516001600160a01b038216907f6719d08c1888103bea251a4ed56406bd0c3e69723c8a1686e017e7bbe159b6f890600090a250565b6119a3610a4e565b6119ef576040805162461bcd60e51b815260206004820152601860248201527714d8da195b59481a5cc81b9bdd081c9959da5cdd195c995960421b604482015290519081900360640190fd5b600354600480546040805130602480830191909152825180830382018152604492830184526020810180516001600160e01b0316635f539d6960e01b17815260025494516368db844d60e11b81526001600160a01b039687169781018881529587169481018590526000606482018190526080948201948552835160848301528351979099169863d1b7089a9897939690949093909260a49092019190808383885b83811015611aa9578181015183820152602001611a91565b50505050905090810190601f168015611ad65780820380516001836020036101000a031916815260200191505b5095505050505050600060405180830381600087803b158015611af857600080fd5b505af1158015611b0c573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040908152811015611b3557600080fd5b815160208301805160405192949293830192919084640100000000821115611b5c57600080fd5b908301906020820185811115611b7157600080fd5b8251640100000000811182820188101715611b8b57600080fd5b82525081516020918201929091019080838360005b83811015611bb8578181015183820152602001611ba0565b50505050905090810190601f168015611be55780820380516001836020036101000a031916815260200191505b5060405250506002546111bb93506001600160a01b031691506117af9050565b611c0d610a4e565b611c59576040805162461bcd60e51b815260206004820152601860248201527714d8da195b59481a5cc81b9bdd081c9959da5cdd195c995960421b604482015290519081900360640190fd5b600354600480546040805130602480830191909152825180830382018152604492830184526020810180516001600160e01b031663c375c2ef60e01b17815260025494516368db844d60e11b81526001600160a01b039687169781018881529587169481018590526000606482018190526080948201948552835160848301528351979099169863d1b7089a9897939690949093909260a49092019190808383885b83811015611d13578181015183820152602001611cfb565b50505050905090810190601f168015611d405780820380516001836020036101000a031916815260200191505b5095505050505050600060405180830381600087803b158015611d6257600080fd5b505af1158015611d76573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040908152811015611d9f57600080fd5b815160208301805160405192949293830192919084640100000000821115611dc657600080fd5b908301906020820185811115611ddb57600080fd5b8251640100000000811182820188101715611df557600080fd5b82525081516020918201929091019080838360005b83811015611e22578181015183820152602001611e0a565b50505050905090810190601f168015611e4f5780820380516001836020036101000a031916815260200191505b506040525050505050565b6001600160a01b038116611e6d57600080fd5b6001546040516001600160a01b0380841692610100900416907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a3600180546001600160a01b0390921661010002610100600160a81b0319909216919091179055565b6000811580611eef57505080820282828281611eec57fe5b04145b6117ec576040805162461bcd60e51b815260206004820152601460248201527364732d6d6174682d6d756c2d6f766572666c6f7760601b604482015290519081900360640190fd5b808201828110156117ec576040805162461bcd60e51b815260206004820152601460248201527364732d6d6174682d6164642d6f766572666c6f7760601b604482015290519081900360640190fd5b6001600160a01b038116611f9957600080fd5b611fa382826118c4565b611fac57600080fd5b6001600160a01b0316600090815260209190915260409020805460ff19169055565b6001600160a01b038116611fe157600080fd5b611feb82826118c4565b15611ff557600080fd5b6001600160a01b0316600090815260209190915260409020805460ff1916600117905556fe596f75206e65656420746f207374616b65206120706f73697469766520746f6b656e20616d6f756e7463616e207265636f7665722063446169206f6e6c79207768656e207374616b65732068617665206265656e2077697468647261776e4f6e6c792046756e644d616e616765722063616e2063616c6c2074686973206d6574686f644d696e74696e672063446169206661696c65642c2066756e64732072657475726e6564526563697069656e742063616e6e6f7420626520746865207374616b696e6720636f6e74726163744e65656420746f207761697420666f7220746865206e65787420696e74657276616c7472616e7366657246726f6d206661696c65642c206d616b65207375726520796f7520617070726f76656420444149207472616e73666572a265627a7a723158208c8b260f403aa9f875b4927de2b87ac43fc28a609654fac761f86260fafcf8e264736f6c63430005100032",
  "sourceMap": "1073:10269:29:-;;;443:64:7;;;-1:-1:-1;;;;;;443:64:7;;;505:1;2874:30:29;;3062:43;;;-1:-1:-1;;3062:43:29;3102:3;3062:43;;;3715:512;5:2:-1;;;;30:1;27;20:12;5:2;3715:512:29;;;;;;;;;;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;-1:-1;3715:512:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;275:22:72;286:10;-1:-1:-1;;;;;275:10:72;:22;:::i;:::-;352:7:74;:15;;-1:-1:-1;;;;;;515:19:77;352:15:74;524:10:77;515:19;;;;;;;;;;549:40;;-1:-1:-1;;;;;582:6:77;;;;;;-1:-1:-1;;549:40:77;;-1:-1:-1;;549:40:77;688:6:7;:16;;-1:-1:-1;;;;;;688:16:7;-1:-1:-1;;;;;688:16:7;;;;;;;;;;;719:6;:19;715:98;;787:6;;;;;;;;;-1:-1:-1;;;;;787:6:7;-1:-1:-1;;;;;787:12:7;;:14;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;787:14:7;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;787:14:7;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;787:14:7;754:10;:48;;-1:-1:-1;;;;;;754:48:7;-1:-1:-1;;;;;754:48:7;;;;;;;;;715:98;-1:-1:-1;;;;;;483:24:11;;475:62;;;;;-1:-1:-1;;;475:62:11;;;;;;;;;;;;;;;;;;;;;;;;;;;;547:8;:20;;-1:-1:-1;;;;;;547:20:11;;;-1:-1:-1;;;;;547:20:11;;;;;;;3943:3:29;:17;;;;;;;;;;3970:4;:20;;;;;;;;;;;;;;-1:-1:-1;;4000:13:29;:30;;;4060:31;:12;4000:30;4060:16;;;;;;;:31;;:::i;:::-;4040:17;:51;4101:11;:26;;-1:-1:-1;;;;;4101:26:29;;;;;-1:-1:-1;;;;;;;;4101:26:29;;;;;;;;;;4212:6;;4194:26;;4212:6;-1:-1:-1;;;;;4194:9:29;:26;:::i;:::-;3715:512;;;;;;1073:10269;;685:119:72;741:21;754:7;741:8;:12;;;;;;:21;;;;:::i;:::-;777:20;;-1:-1:-1;;;;;777:20:72;;;;;;;;685:119;:::o;778:296:76:-;836:7;933:1;929;:5;921:14;;;;;;945:9;961:1;957;:5;;;;;;;778:296;-1:-1:-1;;;;778:296:76:o;508:90:72:-;350:20;359:10;-1:-1:-1;;;;;350:8:72;:20;:::i;:::-;342:29;;;;;;572:19;583:7;-1:-1:-1;;;;;572:10:72;:19;:::i;:::-;508:90;:::o;259:181:70:-;-1:-1:-1;;;;;335:21:70;;327:30;;;;;;376:18;380:4;386:7;-1:-1:-1;;;;;376:3:70;:18;:::i;:::-;375:19;367:28;;;;;;-1:-1:-1;;;;;406:20:70;:11;:20;;;;;;;;;;;:27;;-1:-1:-1;;406:27:70;429:4;406:27;;;259:181::o;395:107:72:-;451:4;474:21;487:7;474:8;:12;;;;;;:21;;;;:::i;:::-;467:28;395:107;-1:-1:-1;;395:107:72:o;786:162:70:-;858:4;-1:-1:-1;;;;;882:21:70;;874:30;;;;;;-1:-1:-1;;;;;;921:20:70;:11;:20;;;;;;;;;;;;;;;786:162::o;1073:10269:29:-;;;;;;;",
  "deployedSourceMap": "1073:10269:29:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1073:10269:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1698:143:7;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;1698:143:7;-1:-1:-1;;;;;1698:143:7;;:::i;:::-;;10834:506:29;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;10834:506:29;-1:-1:-1;;;;;10834:506:29;;:::i;7463:1022::-;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;6920:315;;;:::i;:::-;;;;;;;;;;;;;;;;1987:102:7;;;:::i;:::-;;;;;;;;;;;;;;;;;;4375:107:29;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;4375:107:29;-1:-1:-1;;;;;4375:107:29;;:::i;278:24:11:-;;;:::i;:::-;;;;-1:-1:-1;;;;;278:24:11;;;;;;;;;;;;;;8886:917:29;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;8886:917:29;-1:-1:-1;;;;;8886:917:29;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1176:115:74;;;:::i;395:107:72:-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;395:107:72;-1:-1:-1;;;;;395:107:72;;:::i;460:76:74:-;;;:::i;2735:168:11:-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;2735:168:11;-1:-1:-1;;;;;2735:168:11;;:::i;3160:26:29:-;;;:::i;4756:1081::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;4756:1081:29;;:::i;604:75:72:-;;;:::i;1347:137:77:-;;;:::i;2874:30:29:-;;;:::i;2784:32::-;;;:::i;508:90:72:-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;508:90:72;-1:-1:-1;;;;;508:90:72;;:::i;973:113:74:-;;;:::i;659:77:77:-;;;:::i;979:90::-;;;:::i;1455:41:29:-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;1455:41:29;-1:-1:-1;;;;;1455:41:29;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2500:18;;;:::i;10311:67::-;;;:::i;5904:885::-;;;:::i;2235:262:7:-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;2235:262:7;-1:-1:-1;;;;;2235:262:7;;:::i;2665:28:29:-;;;:::i;10035:124::-;;;:::i;3062:43::-;;;:::i;:::-;;;;;;;;;;;;;;;;;;;10610:81;;;:::i;1655:107:77:-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;1655:107:77;-1:-1:-1;;;;;1655:107:77;;:::i;2451:16:29:-;;;:::i;1698:143:7:-;863:9:77;:7;:9::i;:::-;855:18;;;;;;1760:6:7;:16;;-1:-1:-1;;;;;;1760:16:7;-1:-1:-1;;;;;1760:16:7;;;;;;;;;;;1819:14;;;-1:-1:-1;;;1819:14:7;;;;:6;;;;;:12;;:14;;;;;;;;;;;;;;;:6;:14;;;5:2:-1;;;;30:1;27;20:12;5:2;1819:14:7;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1819:14:7;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;1819:14:7;1786:10;:48;;-1:-1:-1;;;;;;1786:48:7;-1:-1:-1;;;;;1786:48:7;;;;;;;;;-1:-1:-1;1698:143:7:o;10834:506:29:-;932:6:7;;-1:-1:-1;;;;;932:6:7;943:10;924:29;916:74;;;;;-1:-1:-1;;;916:74:7;;;;;;;;;;;;;;;;;;;;;;;;;;;;;10914:31:29;;;-1:-1:-1;;;10914:31:29;;10939:4;10914:31;;;;;;10893:18;;-1:-1:-1;;;;;10914:16:29;;;;;:31;;;;;;;;;;;;;;;:16;:31;;;5:2:-1;;;;30:1;27;20:12;5:2;10914:31:29;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;10914:31:29;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;10914:31:29;11072:4;;10914:31;;-1:-1:-1;;;;;;11045:32:29;;;11072:4;;11045:32;11041:203;;;11118:11;;:16;:28;;;;;11138:8;:6;:8::i;:::-;11093:140;;;;-1:-1:-1;;;11093:140:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;11285:6;;11261:44;;;-1:-1:-1;;;11261:44:29;;-1:-1:-1;;;;;11285:6:29;;;11261:44;;;;;;;;;;;;:15;;;;;;:44;;;;;;;;;;;;;;;11285:6;11261:15;:44;;;5:2:-1;;;;30:1;27;20:12;5:2;11261:44:29;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;11261:44:29;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;11261:44:29;11253:80;;;;;-1:-1:-1;;;11253:80:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;1000:1:7;10834:506:29;:::o;7463:1022::-;7551:7;7572;7593;7625:10;7638:4;;;;;;;;;-1:-1:-1;;;;;7638:4:29;-1:-1:-1;;;;;7638:23:29;;:25;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;7638:25:29;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;7638:25:29;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;7638:25:29;;-1:-1:-1;7673:16:29;7692:17;:15;:17::i;:::-;7673:36;;7735:11;;7723:8;:23;7719:70;;-1:-1:-1;7770:1:29;;-1:-1:-1;7770:1:29;;-1:-1:-1;7770:1:29;;-1:-1:-1;7762:16:29;;-1:-1:-1;7762:16:29;7719:70;7798:16;7817:25;7830:11;;7817:8;:12;;:25;;;;:::i;:::-;7798:44;-1:-1:-1;7984:17:29;8004:28;8009:18;7798:44;8022:4;8009:18;:12;:18;:::i;:::-;8029:2;8004:4;:28::i;:::-;7984:48;-1:-1:-1;8159:28:29;8190:19;7984:48;8204:4;8190:19;:13;:19;:::i;:::-;8159:50;-1:-1:-1;8267:19:29;:9;8281:4;8267:19;:13;:19;:::i;:::-;8255:31;;8355:24;8382:40;8417:4;8382:30;8387:20;8409:2;8382:4;:30::i;:::-;:34;:40;:34;:40;:::i;:::-;8440:9;;-1:-1:-1;8451:8:29;;-1:-1:-1;8355:67:29;;-1:-1:-1;;;;;7463:1022:29;;;;:::o;6920:315::-;6968:7;6987:10;7000:4;;;;;;;;;-1:-1:-1;;;;;7000:4:29;-1:-1:-1;;;;;7000:23:29;;:25;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;7000:25:29;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;7000:25:29;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;7000:25:29;7149:4;;:29;;;-1:-1:-1;;;7149:29:29;;7172:4;7149:29;;;;;;7000:25;;-1:-1:-1;7123:18:29;;7144:57;;7198:2;;7144:49;;7149:39;;7183:4;;-1:-1:-1;;;;;7149:4:29;;;;:14;;:29;;;;;7000:25;;7149:29;;;;;;;;:4;:29;;;5:2:-1;;;;30:1;27;20:12;5:2;7149:29:29;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;7149:29:29;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;7149:29:29;;:39;:33;:39;:::i;:::-;7190:2;7144:4;:49::i;:57::-;7123:78;-1:-1:-1;;;6920:315:29;:::o;1987:102:7:-;2032:4;2055:27;2076:4;2055:12;:27::i;:::-;2048:34;;1987:102;:::o;4375:107:29:-;932:6:7;;-1:-1:-1;;;;;932:6:7;943:10;924:29;916:74;;;;;-1:-1:-1;;;916:74:7;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4449:11:29;:26;;-1:-1:-1;;;;;4449:26:29;;;;;-1:-1:-1;;;;;;4449:26:29;;;;;;;;;4375:107::o;278:24:11:-;;;-1:-1:-1;;;;;278:24:11;;:::o;8886:917:29:-;9003:7;9024;9045;9066:6;3250:11;;;;;;;;;-1:-1:-1;;;;;3250:11:29;-1:-1:-1;;;;;3236:25:29;:10;-1:-1:-1;;;;;3236:25:29;;3228:75;;;;-1:-1:-1;;;3228:75:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;9173:27:29;;9195:4;9173:27;;9165:80;;;;-1:-1:-1;;;9165:80:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;9264:12;:10;:12::i;:::-;9256:59;;;;-1:-1:-1;;;9256:59:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;9340:17;9371:16;9401:24;9438:20;:18;:20::i;:::-;9326:132;;;;;;9488:31;9505:13;;9488:12;:16;;:31;;;;:::i;:::-;9468:17;:51;9533:13;;9529:103;;9568:4;;:36;;;-1:-1:-1;;;9568:36:29;;-1:-1:-1;;;;;9568:36:29;;;;;;;;;;;;;;;:4;;;;;:13;;:36;;;;;;;;;;;;;;:4;;:36;;;5:2:-1;;;;30:1;27;20:12;5:2;9568:36:29;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;9568:36:29;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;9568:36:29;9560:72;;;;;-1:-1:-1;;;9560:72:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;9647:68;;;-1:-1:-1;;;;;9647:68:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;9772:23;;9733:9;;9744:8;;-1:-1:-1;9744:8:29;-1:-1:-1;9772:23:29;;;;;-1:-1:-1;8886:917:29;-1:-1:-1;;8886:917:29:o;1176:115:74:-;350:20:72;359:10;350:8;:20::i;:::-;342:29;;;;;;860:7:74;;;;852:16;;;;;;1234:7;:15;;-1:-1:-1;;1234:15:74;;;1264:20;;;1273:10;1264:20;;;;;;;;;;;;;1176:115::o;395:107:72:-;451:4;474:21;451:4;487:7;474:21;:12;:21;:::i;:::-;467:28;;395:107;;;;:::o;460:76:74:-;522:7;;;;460:76;:::o;2735:168:11:-;863:9:77;:7;:9::i;:::-;855:18;;;;;;2811:9:11;-1:-1:-1;;;;;2811:22:11;;:24;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2811:24:11;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;2811:24:11;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;2811:24:11;2803:63;;;;;-1:-1:-1;;;2803:63:11;;;;;;;;;;;;;;;;;;;;;;;;;;;;2876:8;:20;;-1:-1:-1;;;;;;2876:20:11;-1:-1:-1;;;;;2876:20:11;;;;;;;;;;2735:168::o;3160:26:29:-;;;;;;-1:-1:-1;;;;;3160:26:29;;:::o;4756:1081::-;689:7:74;;;;688:8;680:17;;;;;;4840:1:29;4830:7;:11;4822:65;;;;-1:-1:-1;;;4822:65:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4918:3;;:52;;;-1:-1:-1;;;4918:52:29;;4935:10;4918:52;;;;4955:4;4918:52;;;;;;;;;;;;-1:-1:-1;;;;;4918:3:29;;;;:16;;:52;;;;;;;;;;;;;;;:3;;:52;;;5:2:-1;;;;30:1;27;20:12;5:2;4918:52:29;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;4918:52:29;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;4918:52:29;:60;;4974:4;4918:60;4897:163;;;;-1:-1:-1;;;4897:163:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5111:3;;5131:4;;5111:35;;;-1:-1:-1;;;5111:35:29;;-1:-1:-1;;;;;5131:4:29;;;5111:35;;;;;;;;;;;;:3;;;;;:11;;:35;;;;;;;;;;;;;;:3;;:35;;;5:2:-1;;;;30:1;27;20:12;5:2;5111:35:29;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;5111:35:29;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;;5195:4:29;;:18;;;-1:-1:-1;;;5195:18:29;;;;;;;;;;5181:11;;-1:-1:-1;;;;;5195:4:29;;:9;;:18;;;;;5111:35;;5195:18;;;;;;;5181:11;5195:4;:18;;;5:2:-1;;;;30:1;27;20:12;5:2;5195:18:29;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;5195:18:29;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;5195:18:29;;-1:-1:-1;5402:7:29;;5398:94;;5433:8;;5425:56;;;;-1:-1:-1;;;5425:56:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5571:10;5539:21;5563:19;;;:7;:19;;;;;5611:16;;:29;;5632:7;5611:29;:20;:29;:::i;:::-;5592:48;;5669:12;5650:16;;;:31;5760:11;;:24;;5776:7;5760:24;:15;:24;:::i;:::-;5746:11;:38;5800:30;;;;;;;;5810:10;;5800:30;;;;;;;;;;707:1:74;;4756:1081:29;:::o;604:75:72:-;647:25;661:10;647:13;:25::i;:::-;604:75::o;1347:137:77:-;863:9;:7;:9::i;:::-;855:18;;;;;;1429:6;;1408:40;;1445:1;;1429:6;;;-1:-1:-1;;;;;1429:6:77;;1408:40;;1445:1;;1408:40;1458:6;:19;;-1:-1:-1;;;;;;1458:19:77;;;1347:137::o;2874:30:29:-;;;;:::o;2784:32::-;;;;:::o;508:90:72:-;350:20;359:10;350:8;:20::i;:::-;342:29;;;;;;572:19;583:7;572:10;:19::i;:::-;508:90;:::o;973:113:74:-;350:20:72;359:10;350:8;:20::i;:::-;342:29;;;;;;689:7:74;;;;688:8;680:17;;;;;;1042:4;1032:14;;-1:-1:-1;;1032:14:74;;;;;1061:18;;;1068:10;1061:18;;;;;;;;;;;;;973:113::o;659:77:77:-;723:6;;;;;-1:-1:-1;;;;;723:6:77;;659:77::o;979:90::-;1056:6;;;;;-1:-1:-1;;;;;1056:6:77;1042:10;:20;;979:90::o;1455:41:29:-;;;;;;;;;;;;;;;;;;;:::o;2500:18::-;;;-1:-1:-1;;;;;2500:18:29;;:::o;10311:67::-;1121:14:7;:12;:14::i;:::-;1113:51;;;;;-1:-1:-1;;;1113:51:7;;;;;;;;;;;;-1:-1:-1;;;1113:51:7;;;;;;;;;;;;;;;10360:11:29;:9;:11::i;5904:885::-;5978:10;5946:21;5970:19;;;:7;:19;;;;;6007:16;;5999:46;;;;;-1:-1:-1;;;5999:46:29;;;;;;;;;;;;-1:-1:-1;;;5999:46:29;;;;;;;;;;;;;;;6063:4;;6085:16;;6063:39;;;-1:-1:-1;;;6063:39:29;;;;;;;;;;-1:-1:-1;;;;;6063:4:29;;;;:21;;:39;;;;;;;;;;;;;;;:4;;:39;;;5:2:-1;;;;30:1;27;20:12;5:2;6063:39:29;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6063:39:29;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;6063:39:29;:44;6055:78;;;;;-1:-1:-1;;;6055:78:29;;;;;;;;;;;;-1:-1:-1;;;6055:78:29;;;;;;;;;;;;;;;6165:16;;6143:19;6255:20;;6300:11;;:28;;6165:16;6300:28;:15;:28;:::i;:::-;6286:11;:42;6517:3;;:28;;;-1:-1:-1;;;6517:28:29;;6539:4;6517:28;;;;;;6497:17;;-1:-1:-1;;;;;6517:3:29;;:13;;:28;;;;;;;;;;;;;;:3;:28;;;5:2:-1;;;;30:1;27;20:12;5:2;6517:28:29;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6517:28:29;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;6517:28:29;;-1:-1:-1;6559:23:29;;;6555:77;;;6612:9;6598:23;;6555:77;6649:3;;:37;;;-1:-1:-1;;;6649:37:29;;6662:10;6649:37;;;;;;;;;;;;-1:-1:-1;;;;;6649:3:29;;;;:12;;:37;;;;;;;;;;;;;;;:3;;:37;;;5:2:-1;;;;30:1;27;20:12;5:2;6649:37:29;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6649:37:29;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;6649:37:29;6641:74;;;;;-1:-1:-1;;;6641:74:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;6730:52;;;;;;;;;;;;;;6747:10;;6730:52;;;;;;;;5904:885;;;:::o;2235:262:7:-;2318:6;;2294:4;;-1:-1:-1;;;;;2318:6:7;2310:49;;;;;-1:-1:-1;;;2310:49:7;;;;;;;;;;;;-1:-1:-1;;;2310:49:7;;;;;;;;;;;;;;;2376:10;;2422:6;;2376:54;;;-1:-1:-1;;;2376:54:7;;-1:-1:-1;;;;;2376:54:7;;;;;;;2422:6;;;2376:54;;;;;;:10;;;;;:29;;:54;;;;;;;;;;;;;;:10;:54;;;5:2:-1;;;;30:1;27;20:12;5:2;2376:54:7;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;2376:54:7;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;2376:54:7;2370:100;;-1:-1:-1;2454:5:7;2447:12;;2370:100;-1:-1:-1;2486:4:7;2235:262;;;:::o;2665:28:29:-;;;;:::o;10035:124::-;10078:4;10135:17;;10101:31;10118:13;;10101:12;:16;;:31;;;;:::i;:::-;:51;10094:58;;10035:124;:::o;3062:43::-;;;;;;:::o;10610:81::-;932:6:7;;-1:-1:-1;;;;;932:6:7;943:10;924:29;916:74;;;;;-1:-1:-1;;;916:74:7;;;;;;;;;;;;;;;;;;;;;;;;;;;;;10653:7:29;:5;:7::i;:::-;10670:14;:12;:14::i;1655:107:77:-;863:9;:7;:9::i;:::-;855:18;;;;;;1727:28;1746:8;1727:18;:28::i;2451:16:29:-;;;-1:-1:-1;;;;;2451:16:29;;:::o;1205:145:76:-;1263:7;1295:1;1290;:6;;1282:15;;;;;;-1:-1:-1;1319:5:76;;;1205:145;;;;;:::o;229:421::-;287:7;527:6;523:45;;-1:-1:-1;556:1:76;549:8;;523:45;590:5;;;594:1;590;:5;:1;613:5;;;;;:10;605:19;;;;;;642:1;229:421;-1:-1:-1;;;229:421:76:o;2069:118:0:-;2128:9;2179:1;2153:23;2157:11;2161:1;1683:6;2157:3;:11::i;:::-;2174:1;2170;:5;;2153:3;:23::i;:::-;:27;;;;;;;2069:118;-1:-1:-1;;;2069:118:0:o;1728:121:76:-;1786:7;1813:6;1805:15;;;;;;1841:1;1837;:5;;;;;;;1728:121;-1:-1:-1;;;1728:121:76:o;778:296::-;836:7;933:1;929;:5;921:14;;;;;;945:9;961:1;957;:5;;;;;;;778:296;-1:-1:-1;;;;778:296:76:o;1821:120:0:-;1880:9;1683:6;1905:23;1909:9;1913:1;1916;1909:3;:9::i;:::-;1926:1;1683:6;1920:7;;786:162:70;858:4;-1:-1:-1;;;;;882:21:70;;874:30;;;;;;-1:-1:-1;;;;;;921:20:70;:11;:20;;;;;;;;;;;;;;;786:162::o;1431:145:76:-;1489:7;1520:5;;;1543:6;;;;1535:15;;;;;810:127:72;869:24;:8;885:7;869:24;:15;:24;:::i;:::-;908:22;;-1:-1:-1;;;;;908:22:72;;;;;;;;810:127;:::o;685:119::-;741:21;:8;754:7;741:21;:12;:21;:::i;:::-;777:20;;-1:-1:-1;;;;;777:20:72;;;;;;;;685:119;:::o;786:280:5:-;1121:14:7;:12;:14::i;:::-;1113:51;;;;;-1:-1:-1;;;1113:51:7;;;;;;;;;;;;-1:-1:-1;;;1113:51:7;;;;;;;;;;;;;;;841:10:5;;885:8;;;908:62;;;964:4;908:62;;;;;;;;;;26:21:-1;;;22:32;;6:49;;908:62:5;;;;;;;25:18:-1;;61:17;;-1:-1;;;;;182:15;-1:-1;;;179:29;160:49;;984:6:5;;841:174;;-1:-1:-1;;;841:174:5;;-1:-1:-1;;;;;885:8:5;;;841:174;;;;;;984:6;;;841:174;;;;;;:10;:174;;;;;;;;;;;;;;;;;;;;;:10;;;;;:22;;885:8;908:62;;841:10;;:174;;;;;;;;;25:18:-1;841:174:5;;25:18:-1;841:10:5;8:100:-1;33:3;30:1;27:10;8:100;;;90:11;;;84:18;71:11;;;64:39;52:2;45:10;8:100;;;12:14;841:174:5;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;841:174:5;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;841:174:5;;;;;;39:16:-1;36:1;17:17;2:54;101:4;841:174:5;80:15:-1;;;-1:-1;;76:31;65:43;;120:4;113:20;;;5:11;;2:2;;;29:1;26;19:12;2:2;841:174:5;;;;;;;;;;;;;;;;;;;19:11:-1;11:20;;8:2;;;44:1;41;34:12;8:2;62:21;;;;123:4;114:14;;138:31;;;135:2;;;182:1;179;172:12;135:2;213:10;;261:11;244:29;;285:43;;;282:58;-1:-1;233:115;230:2;;;361:1;358;351:12;230:2;372:25;;-1:-1;841:174:5;;420:4:-1;411:14;;;;841:174:5;;;;;411:14:-1;841:174:5;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;90:11;;;84:18;71:11;;;64:39;52:2;45:10;8:100;;;12:14;841:174:5;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;841:174:5;;-1:-1:-1;;1051:6:5;;1025:34;;-1:-1:-1;;;;;;1051:6:5;;-1:-1:-1;1025:17:5;;-1:-1:-1;1025:34:5:i;1195:242::-;1121:14:7;:12;:14::i;:::-;1113:51;;;;;-1:-1:-1;;;1113:51:7;;;;;;;;;;;;-1:-1:-1;;;1113:51:7;;;;;;;;;;;;;;;1253:10:5;;1297:8;;;1320:65;;;1379:4;1320:65;;;;;;;;;;26:21:-1;;;22:32;;6:49;;1320:65:5;;;;;;;25:18:-1;;61:17;;-1:-1;;;;;182:15;-1:-1;;;179:29;160:49;;1399:6:5;;1253:177;;-1:-1:-1;;;1253:177:5;;-1:-1:-1;;;;;1297:8:5;;;1253:177;;;;;;1399:6;;;1253:177;;;;;;:10;:177;;;;;;;;;;;;;;;;;;;;;:10;;;;;:22;;1297:8;1320:65;;1253:10;;:177;;;;;;;;;25:18:-1;1253:177:5;;25:18:-1;1253:10:5;8:100:-1;33:3;30:1;27:10;8:100;;;90:11;;;84:18;71:11;;;64:39;52:2;45:10;8:100;;;12:14;1253:177:5;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1253:177:5;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1253:177:5;;;;;;39:16:-1;36:1;17:17;2:54;101:4;1253:177:5;80:15:-1;;;-1:-1;;76:31;65:43;;120:4;113:20;;;5:11;;2:2;;;29:1;26;19:12;2:2;1253:177:5;;;;;;;;;;;;;;;;;;;19:11:-1;11:20;;8:2;;;44:1;41;34:12;8:2;62:21;;;;123:4;114:14;;138:31;;;135:2;;;182:1;179;172:12;135:2;213:10;;261:11;244:29;;285:43;;;282:58;-1:-1;233:115;230:2;;;361:1;358;351:12;230:2;372:25;;-1:-1;1253:177:5;;420:4:-1;411:14;;;;1253:177:5;;;;;411:14:-1;1253:177:5;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;90:11;;;84:18;71:11;;;64:39;52:2;45:10;8:100;;;12:14;1253:177:5;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1195:242::o;1906:183:77:-;-1:-1:-1;;;;;1979:22:77;;1971:31;;;;;;2038:6;;2017:38;;-1:-1:-1;;;;;2017:38:77;;;;2038:6;;;;;2017:38;;;;;2065:6;:17;;-1:-1:-1;;;;;2065:17:77;;;;;-1:-1:-1;;;;;;2065:17:77;;;;;;;;;1906:183::o;1025:149:0:-;1083:9;1112:6;;;:30;;-1:-1:-1;;1127:5:0;;;1141:1;1136;1127:5;1136:1;1122:15;;;;;:20;1112:30;1104:63;;;;;-1:-1:-1;;;1104:63:0;;;;;;;;;;;;-1:-1:-1;;;1104:63:0;;;;;;;;;;;;;;744:135;836:5;;;831:16;;;;823:49;;;;;-1:-1:-1;;;823:49:0;;;;;;;;;;;;-1:-1:-1;;;823:49:0;;;;;;;;;;;;;;514:184:70;-1:-1:-1;;;;;593:21:70;;585:30;;;;;;633:18;637:4;643:7;633:3;:18::i;:::-;625:27;;;;;;-1:-1:-1;;;;;663:20:70;686:5;663:20;;;;;;;;;;;:28;;-1:-1:-1;;663:28:70;;;514:184::o;259:181::-;-1:-1:-1;;;;;335:21:70;;327:30;;;;;;376:18;380:4;386:7;376:3;:18::i;:::-;375:19;367:28;;;;;;-1:-1:-1;;;;;406:20:70;:11;:20;;;;;;;;;;;:27;;-1:-1:-1;;406:27:70;429:4;406:27;;;259:181::o",
  "source": "pragma solidity >0.5.4;\n\nimport \"openzeppelin-solidity/contracts/math/SafeMath.sol\";\nimport \"openzeppelin-solidity/contracts/lifecycle/Pausable.sol\";\nimport \"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\";\nimport \"@daostack/arc/contracts/controller/Avatar.sol\";\nimport \"../../contracts/dao/schemes/FeelessScheme.sol\";\nimport \"../../contracts/identity/Identity.sol\";\nimport \"../../contracts/DSMath.sol\";\n\ninterface cERC20 {\n    function mint(uint256 mintAmount) external returns (uint256);\n\n    function redeemUnderlying(uint256 mintAmount) external returns (uint256);\n\n    function exchangeRateCurrent() external returns (uint256);\n\n    function exchangeRateStored() external view returns (uint256);\n\n    function balanceOf(address addr) external view returns (uint256);\n\n    function transfer(address to, uint256 amount) external returns (bool);\n}\n\n/**\n * @title Staking contract that donates earned interest to the DAO\n * allowing stakers to deposit DAI or withdraw their stake in DAI.\n * The contract buys cDAI and can transfer the daily interest to the DAO\n */\ncontract SimpleDAIStaking is DSMath, Pausable, FeelessScheme {\n    using SafeMath for uint256;\n\n    // Entity that holds a staker info\n    struct Staker {\n        // The staked DAI amount\n        uint256 stakedDAI;\n        // The latest block number which the\n        // staker has staked tokens\n        uint256 lastStake;\n    }\n\n    // The map which holds the stakers entities\n    mapping(address => Staker) public stakers;\n\n    // Emits when new DAI tokens have been staked\n    event DAIStaked(\n        // The staker address\n        address indexed staker,\n        // How many tokens have been staked\n        uint256 daiValue\n    );\n\n    // Emits when DAI tokens are being withdrawn\n    event DAIStakeWithdraw(\n        // The staker that initiate the action\n        address indexed staker,\n        // The initial DAI value that was staked\n        uint256 daiValue,\n        // The current DAI value that was staked\n        uint256 daiActual\n    );\n\n    // Emits when the interest is collected\n    event InterestCollected(\n        // Who is receives the interest\n        address recipient,\n        // How many cDAI tokens have been transferred\n        uint256 cdaiValue,\n        // The worth of the transferred tokens in DAI\n        uint256 daiValue,\n        // Lost amount. A result of different precisions\n        uint256 daiPrecisionLoss\n    );\n\n    // DAI token address\n    ERC20 public dai;\n\n    // cDAI token address\n    cERC20 public cDai;\n\n    // The block interval defines the number of\n    // blocks that shall be passed before the\n    // next execution of `collectUBIInterest`\n    uint256 public blockInterval;\n\n    // The last block number which\n    // `collectUBIInterest` has been executed in\n    uint256 public lastUBICollection;\n\n    // The total staked DAI amount in the contract\n    uint256 public totalStaked = 0;\n\n    // How much of the generated interest is donated,\n    // meaning no GD is expected in compensation, 1 in mil precision.\n    // 100% for phase0 POC\n    uint32 public avgInterestDonatedRatio = 1e6;\n\n    // The address of the fund manager contract\n    address public fundManager;\n\n    modifier onlyFundManager {\n        require(msg.sender == fundManager, \"Only FundManager can call this method\");\n        _;\n    }\n\n    /**\n     * @dev Constructor\n     * @param _dai The address of DAI\n     * @param _cDai The address of cDAI\n     * @param _fundManager The address of the fund manager contract\n     * @param _blockInterval How many blocks should be passed before the next execution of `collectUBIInterest`\n     * @param _avatar The avatar of the DAO\n     * @param _identity The identity contract\n     */\n    constructor(\n        address _dai,\n        address _cDai,\n        address _fundManager,\n        uint256 _blockInterval,\n        Avatar _avatar,\n        Identity _identity\n    ) public FeelessScheme(_identity, _avatar) {\n        dai = ERC20(_dai);\n        cDai = cERC20(_cDai);\n        blockInterval = _blockInterval;\n        lastUBICollection = block.number.div(blockInterval);\n        fundManager = _fundManager;\n\n        // Adds the avatar as a pauser of this contract\n        addPauser(address(avatar));\n    }\n\n    /**\n     * @dev Allows the DAO to change the fund manager contract address\n     * @param _fundManager Address of the new contract\n     */\n    function setFundManager(address _fundManager) public onlyAvatar {\n        fundManager = _fundManager;\n    }\n\n    /**\n     * @dev Allows a staker to deposit DAI tokens. Notice that `approve` is\n     * needed to be executed before the execution of this method.\n     * Can be executed only when the contract is not paused.\n     * @param _amount The amount of DAI to stake\n     */\n    function stakeDAI(uint256 _amount) public whenNotPaused {\n        require(_amount > 0, \"You need to stake a positive token amount\");\n        require(\n            dai.transferFrom(msg.sender, address(this), _amount) == true,\n            \"transferFrom failed, make sure you approved DAI transfer\"\n        );\n\n        // approve the transfer to cDAI\n        dai.approve(address(cDai), _amount);\n\n        // mint ctokens\n        uint256 res = cDai.mint(_amount);\n\n        // cDAI returns >0 if error happened while minting.\n        // Makes sure that there are no errors. If an error\n        // has occurred, DAI funds shall be returned.\n        if (res > 0) {\n            require(res == 0, \"Minting cDai failed, funds returned\");\n        }\n\n        // updated the staker entity\n        Staker storage staker = stakers[msg.sender];\n        staker.stakedDAI = staker.stakedDAI.add(_amount);\n        staker.lastStake = block.number;\n\n        // adds the staked amount to the total staked\n        totalStaked = totalStaked.add(_amount);\n\n        emit DAIStaked(msg.sender, _amount);\n    }\n\n    /**\n     * @dev Withdraws the sender staked DAI.\n     */\n    function withdrawStake() public {\n        Staker storage staker = stakers[msg.sender];\n        require(staker.stakedDAI > 0, \"No DAI staked\");\n        require(cDai.redeemUnderlying(staker.stakedDAI) == 0, \"Failed to redeem cDai\");\n        uint256 daiWithdraw = staker.stakedDAI;\n\n        // updates balance before transfer to prevent re-entry\n        staker.stakedDAI = 0;\n\n        totalStaked = totalStaked.sub(daiWithdraw);\n\n        //redeeming in compound may result in a tiny fraction of precission error\n        //so if we redeem 100 DAI we might get something like 99.9999999999\n        uint256 daiActual = dai.balanceOf(address(this));\n        if (daiActual < daiWithdraw) {\n            daiWithdraw = daiActual;\n        }\n        require(dai.transfer(msg.sender, daiWithdraw), \"withdraw transfer failed\");\n        emit DAIStakeWithdraw(msg.sender, daiWithdraw, daiActual);\n    }\n\n    /**\n     * @dev Calculates the worth of the staked cDAI tokens in DAI.\n     * @return (uint256) The worth in DAI\n     */\n    function currentDAIWorth() public view returns (uint256) {\n        uint256 er = cDai.exchangeRateStored();\n\n        //TODO: why 1e10? cDai is e8 so we should convert it to e28 like exchange rate\n        uint256 daiBalance = rmul(cDai.balanceOf(address(this)).mul(1e10), er).div(10);\n        return daiBalance;\n    }\n\n    /**\n     * @dev Calculates the current interest that was gained.\n     * @return (uint256, uint256, uint256) The interest in cDAI, the interest in DAI,\n     * the amount which is not covered by precision of DAI\n     */\n    function currentUBIInterest()\n        public\n        view\n        returns (\n            uint256,\n            uint256,\n            uint256\n        )\n    {\n        uint256 er = cDai.exchangeRateStored();\n        uint256 daiWorth = currentDAIWorth();\n        if (daiWorth <= totalStaked) {\n            return (0, 0, 0);\n        }\n        uint256 daiGains = daiWorth.sub(totalStaked);\n        // mul by 1e10 to equalize precision otherwise since exchangerate\n        // is very big, dividing by it would result in 0.\n        uint256 cdaiGains = rdiv(daiGains.mul(1e10), er);\n        // gets right most bits not covered by precision of cdai which is\n        // only 8 decimals while RAY is 27\n        uint256 precisionLossCDaiRay = cdaiGains.mod(1e19);\n        // lower back to 8 decimals\n        cdaiGains = cdaiGains.div(1e19);\n        //div by 1e10 to get results in dai precision 1e18\n        uint256 precisionLossDai = rmul(precisionLossCDaiRay, er).div(1e10);\n        return (cdaiGains, daiGains, precisionLossDai);\n    }\n\n    /**\n     * @dev Collects gained interest by fundmanager. Can be collected only once\n     * in an interval which is defined above.\n     * @param _recipient The recipient of cDAI gains\n     * @return (uint256, uint256, uint256, uint32) The interest in cDAI, the interest in DAI,\n     * the amount which is not covered by precision of DAI, how much of the generated interest is donated\n     */\n    function collectUBIInterest(address _recipient)\n        public\n        onlyFundManager\n        returns (\n            uint256,\n            uint256,\n            uint256,\n            uint32\n        )\n    {\n        // otherwise fund manager has to wait for the next interval\n        require(_recipient != address(this), \"Recipient cannot be the staking contract\");\n\n        require(canCollect(), \"Need to wait for the next interval\");\n\n        (\n            uint256 cdaiGains,\n            uint256 daiGains,\n            uint256 precisionLossDai\n        ) = currentUBIInterest();\n        lastUBICollection = block.number.div(blockInterval);\n        if (cdaiGains > 0)\n            require(cDai.transfer(_recipient, cdaiGains), \"collect transfer failed\");\n        emit InterestCollected(_recipient, cdaiGains, daiGains, precisionLossDai);\n        return (cdaiGains, daiGains, precisionLossDai, avgInterestDonatedRatio);\n    }\n\n    /**\n     * @dev Checks if enough blocks have passed so it would be possible to\n     * execute `collectUBIInterest` according to the length of `blockInterval`\n     * @return (bool) True if enough blocks have passed\n     */\n    function canCollect() public view returns (bool) {\n        return block.number.div(blockInterval) > lastUBICollection;\n    }\n\n    /**\n     * @dev Start function. Adds this contract to identity as a feeless scheme.\n     * Can only be called if scheme is registered\n     */\n    function start() public onlyRegistered {\n        addRights();\n    }\n\n    /**\n     * @dev making the contract inactive\n     * NOTICE: this could theoretically result in future interest earned in cdai to remain locked\n     * but we dont expect any other stakers but us in SimpleDAIStaking\n     */\n    function end() public onlyAvatar {\n        pause();\n        removeRights();\n    }\n\n    /**\n     * @dev method to recover any stuck erc20 tokens (ie  compound COMP)\n     * @param _token the ERC20 token to recover\n     */\n    function recover(ERC20 _token) public onlyAvatar {\n        uint256 toWithdraw = _token.balanceOf(address(this));\n\n        // recover left cDai(stakers token) only when all stakes have been withdrawn\n        if (address(_token) == address(cDai)) {\n            require(\n                totalStaked == 0 && paused(),\n                \"can recover cDai only when stakes have been withdrawn\"\n            );\n        }\n        require(_token.transfer(address(avatar), toWithdraw), \"recover transfer failed\");\n    }\n}\n",
  "sourcePath": "/Users/hadar/workspace/GoodDollar/GoodBootstrap/packages/contracts/stakingModel/contracts/SimpleDAIStaking.sol",
  "ast": {
    "absolutePath": "/Users/hadar/workspace/GoodDollar/GoodBootstrap/packages/contracts/stakingModel/contracts/SimpleDAIStaking.sol",
    "exportedSymbols": {
      "SimpleDAIStaking": [
        9740
      ],
      "cERC20": [
        9160
      ]
    },
    "id": 9741,
    "nodeType": "SourceUnit",
    "nodes": [
      {
        "id": 9112,
        "literals": [
          "solidity",
          ">",
          "0.5",
          ".4"
        ],
        "nodeType": "PragmaDirective",
        "src": "0:23:29"
      },
      {
        "absolutePath": "openzeppelin-solidity/contracts/math/SafeMath.sol",
        "file": "openzeppelin-solidity/contracts/math/SafeMath.sol",
        "id": 9113,
        "nodeType": "ImportDirective",
        "scope": 9741,
        "sourceUnit": 21309,
        "src": "25:59:29",
        "symbolAliases": [],
        "unitAlias": ""
      },
      {
        "absolutePath": "openzeppelin-solidity/contracts/lifecycle/Pausable.sol",
        "file": "openzeppelin-solidity/contracts/lifecycle/Pausable.sol",
        "id": 9114,
        "nodeType": "ImportDirective",
        "scope": 9741,
        "sourceUnit": 21112,
        "src": "85:64:29",
        "symbolAliases": [],
        "unitAlias": ""
      },
      {
        "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/ERC20.sol",
        "file": "openzeppelin-solidity/contracts/token/ERC20/ERC20.sol",
        "id": 9115,
        "nodeType": "ImportDirective",
        "scope": 9741,
        "sourceUnit": 21850,
        "src": "150:63:29",
        "symbolAliases": [],
        "unitAlias": ""
      },
      {
        "absolutePath": "@daostack/arc/contracts/controller/Avatar.sol",
        "file": "@daostack/arc/contracts/controller/Avatar.sol",
        "id": 9116,
        "nodeType": "ImportDirective",
        "scope": 9741,
        "sourceUnit": 12706,
        "src": "214:55:29",
        "symbolAliases": [],
        "unitAlias": ""
      },
      {
        "absolutePath": "/Users/hadar/workspace/GoodDollar/GoodBootstrap/packages/contracts/contracts/dao/schemes/FeelessScheme.sol",
        "file": "../../contracts/dao/schemes/FeelessScheme.sol",
        "id": 9117,
        "nodeType": "ImportDirective",
        "scope": 9741,
        "sourceUnit": 1228,
        "src": "270:55:29",
        "symbolAliases": [],
        "unitAlias": ""
      },
      {
        "absolutePath": "/Users/hadar/workspace/GoodDollar/GoodBootstrap/packages/contracts/contracts/identity/Identity.sol",
        "file": "../../contracts/identity/Identity.sol",
        "id": 9118,
        "nodeType": "ImportDirective",
        "scope": 9741,
        "sourceUnit": 2381,
        "src": "326:47:29",
        "symbolAliases": [],
        "unitAlias": ""
      },
      {
        "absolutePath": "/Users/hadar/workspace/GoodDollar/GoodBootstrap/packages/contracts/contracts/DSMath.sol",
        "file": "../../contracts/DSMath.sol",
        "id": 9119,
        "nodeType": "ImportDirective",
        "scope": 9741,
        "sourceUnit": 304,
        "src": "374:36:29",
        "symbolAliases": [],
        "unitAlias": ""
      },
      {
        "baseContracts": [],
        "contractDependencies": [],
        "contractKind": "interface",
        "documentation": null,
        "fullyImplemented": false,
        "id": 9160,
        "linearizedBaseContracts": [
          9160
        ],
        "name": "cERC20",
        "nodeType": "ContractDefinition",
        "nodes": [
          {
            "body": null,
            "documentation": null,
            "id": 9126,
            "implemented": false,
            "kind": "function",
            "modifiers": [],
            "name": "mint",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9122,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9121,
                  "name": "mintAmount",
                  "nodeType": "VariableDeclaration",
                  "scope": 9126,
                  "src": "449:18:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9120,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "449:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "448:20:29"
            },
            "returnParameters": {
              "id": 9125,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9124,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 9126,
                  "src": "487:7:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9123,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "487:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "486:9:29"
            },
            "scope": 9160,
            "src": "435:61:29",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "external"
          },
          {
            "body": null,
            "documentation": null,
            "id": 9133,
            "implemented": false,
            "kind": "function",
            "modifiers": [],
            "name": "redeemUnderlying",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9129,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9128,
                  "name": "mintAmount",
                  "nodeType": "VariableDeclaration",
                  "scope": 9133,
                  "src": "528:18:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9127,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "528:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "527:20:29"
            },
            "returnParameters": {
              "id": 9132,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9131,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 9133,
                  "src": "566:7:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9130,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "566:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "565:9:29"
            },
            "scope": 9160,
            "src": "502:73:29",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "external"
          },
          {
            "body": null,
            "documentation": null,
            "id": 9138,
            "implemented": false,
            "kind": "function",
            "modifiers": [],
            "name": "exchangeRateCurrent",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9134,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "609:2:29"
            },
            "returnParameters": {
              "id": 9137,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9136,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 9138,
                  "src": "630:7:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9135,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "630:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "629:9:29"
            },
            "scope": 9160,
            "src": "581:58:29",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "external"
          },
          {
            "body": null,
            "documentation": null,
            "id": 9143,
            "implemented": false,
            "kind": "function",
            "modifiers": [],
            "name": "exchangeRateStored",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9139,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "672:2:29"
            },
            "returnParameters": {
              "id": 9142,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9141,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 9143,
                  "src": "698:7:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9140,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "698:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "697:9:29"
            },
            "scope": 9160,
            "src": "645:62:29",
            "stateMutability": "view",
            "superFunction": null,
            "visibility": "external"
          },
          {
            "body": null,
            "documentation": null,
            "id": 9150,
            "implemented": false,
            "kind": "function",
            "modifiers": [],
            "name": "balanceOf",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9146,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9145,
                  "name": "addr",
                  "nodeType": "VariableDeclaration",
                  "scope": 9150,
                  "src": "732:12:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 9144,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "732:7:29",
                    "stateMutability": "nonpayable",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "731:14:29"
            },
            "returnParameters": {
              "id": 9149,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9148,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 9150,
                  "src": "769:7:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9147,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "769:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "768:9:29"
            },
            "scope": 9160,
            "src": "713:65:29",
            "stateMutability": "view",
            "superFunction": null,
            "visibility": "external"
          },
          {
            "body": null,
            "documentation": null,
            "id": 9159,
            "implemented": false,
            "kind": "function",
            "modifiers": [],
            "name": "transfer",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9155,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9152,
                  "name": "to",
                  "nodeType": "VariableDeclaration",
                  "scope": 9159,
                  "src": "802:10:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 9151,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "802:7:29",
                    "stateMutability": "nonpayable",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9154,
                  "name": "amount",
                  "nodeType": "VariableDeclaration",
                  "scope": 9159,
                  "src": "814:14:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9153,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "814:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "801:28:29"
            },
            "returnParameters": {
              "id": 9158,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9157,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 9159,
                  "src": "848:4:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_bool",
                    "typeString": "bool"
                  },
                  "typeName": {
                    "id": 9156,
                    "name": "bool",
                    "nodeType": "ElementaryTypeName",
                    "src": "848:4:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "847:6:29"
            },
            "scope": 9160,
            "src": "784:70:29",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "external"
          }
        ],
        "scope": 9741,
        "src": "412:444:29"
      },
      {
        "baseContracts": [
          {
            "arguments": null,
            "baseName": {
              "contractScope": null,
              "id": 9161,
              "name": "DSMath",
              "nodeType": "UserDefinedTypeName",
              "referencedDeclaration": 303,
              "src": "1102:6:29",
              "typeDescriptions": {
                "typeIdentifier": "t_contract$_DSMath_$303",
                "typeString": "contract DSMath"
              }
            },
            "id": 9162,
            "nodeType": "InheritanceSpecifier",
            "src": "1102:6:29"
          },
          {
            "arguments": null,
            "baseName": {
              "contractScope": null,
              "id": 9163,
              "name": "Pausable",
              "nodeType": "UserDefinedTypeName",
              "referencedDeclaration": 21111,
              "src": "1110:8:29",
              "typeDescriptions": {
                "typeIdentifier": "t_contract$_Pausable_$21111",
                "typeString": "contract Pausable"
              }
            },
            "id": 9164,
            "nodeType": "InheritanceSpecifier",
            "src": "1110:8:29"
          },
          {
            "arguments": null,
            "baseName": {
              "contractScope": null,
              "id": 9165,
              "name": "FeelessScheme",
              "nodeType": "UserDefinedTypeName",
              "referencedDeclaration": 1227,
              "src": "1120:13:29",
              "typeDescriptions": {
                "typeIdentifier": "t_contract$_FeelessScheme_$1227",
                "typeString": "contract FeelessScheme"
              }
            },
            "id": 9166,
            "nodeType": "InheritanceSpecifier",
            "src": "1120:13:29"
          }
        ],
        "contractDependencies": [
          303,
          1227,
          1423,
          2667,
          20947,
          21111,
          21417
        ],
        "contractKind": "contract",
        "documentation": "@title Staking contract that donates earned interest to the DAO\nallowing stakers to deposit DAI or withdraw their stake in DAI.\nThe contract buys cDAI and can transfer the daily interest to the DAO",
        "fullyImplemented": true,
        "id": 9740,
        "linearizedBaseContracts": [
          9740,
          1227,
          2667,
          1423,
          21417,
          21111,
          20947,
          303
        ],
        "name": "SimpleDAIStaking",
        "nodeType": "ContractDefinition",
        "nodes": [
          {
            "id": 9169,
            "libraryName": {
              "contractScope": null,
              "id": 9167,
              "name": "SafeMath",
              "nodeType": "UserDefinedTypeName",
              "referencedDeclaration": 21308,
              "src": "1146:8:29",
              "typeDescriptions": {
                "typeIdentifier": "t_contract$_SafeMath_$21308",
                "typeString": "library SafeMath"
              }
            },
            "nodeType": "UsingForDirective",
            "src": "1140:27:29",
            "typeName": {
              "id": 9168,
              "name": "uint256",
              "nodeType": "ElementaryTypeName",
              "src": "1159:7:29",
              "typeDescriptions": {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              }
            }
          },
          {
            "canonicalName": "SimpleDAIStaking.Staker",
            "id": 9174,
            "members": [
              {
                "constant": false,
                "id": 9171,
                "name": "stakedDAI",
                "nodeType": "VariableDeclaration",
                "scope": 9174,
                "src": "1269:17:29",
                "stateVariable": false,
                "storageLocation": "default",
                "typeDescriptions": {
                  "typeIdentifier": "t_uint256",
                  "typeString": "uint256"
                },
                "typeName": {
                  "id": 9170,
                  "name": "uint256",
                  "nodeType": "ElementaryTypeName",
                  "src": "1269:7:29",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  }
                },
                "value": null,
                "visibility": "internal"
              },
              {
                "constant": false,
                "id": 9173,
                "name": "lastStake",
                "nodeType": "VariableDeclaration",
                "scope": 9174,
                "src": "1377:17:29",
                "stateVariable": false,
                "storageLocation": "default",
                "typeDescriptions": {
                  "typeIdentifier": "t_uint256",
                  "typeString": "uint256"
                },
                "typeName": {
                  "id": 9172,
                  "name": "uint256",
                  "nodeType": "ElementaryTypeName",
                  "src": "1377:7:29",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  }
                },
                "value": null,
                "visibility": "internal"
              }
            ],
            "name": "Staker",
            "nodeType": "StructDefinition",
            "scope": 9740,
            "src": "1212:189:29",
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 9178,
            "name": "stakers",
            "nodeType": "VariableDeclaration",
            "scope": 9740,
            "src": "1455:41:29",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_mapping$_t_address_$_t_struct$_Staker_$9174_storage_$",
              "typeString": "mapping(address => struct SimpleDAIStaking.Staker)"
            },
            "typeName": {
              "id": 9177,
              "keyType": {
                "id": 9175,
                "name": "address",
                "nodeType": "ElementaryTypeName",
                "src": "1463:7:29",
                "typeDescriptions": {
                  "typeIdentifier": "t_address",
                  "typeString": "address"
                }
              },
              "nodeType": "Mapping",
              "src": "1455:26:29",
              "typeDescriptions": {
                "typeIdentifier": "t_mapping$_t_address_$_t_struct$_Staker_$9174_storage_$",
                "typeString": "mapping(address => struct SimpleDAIStaking.Staker)"
              },
              "valueType": {
                "contractScope": null,
                "id": 9176,
                "name": "Staker",
                "nodeType": "UserDefinedTypeName",
                "referencedDeclaration": 9174,
                "src": "1474:6:29",
                "typeDescriptions": {
                  "typeIdentifier": "t_struct$_Staker_$9174_storage_ptr",
                  "typeString": "struct SimpleDAIStaking.Staker"
                }
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "anonymous": false,
            "documentation": null,
            "id": 9184,
            "name": "DAIStaked",
            "nodeType": "EventDefinition",
            "parameters": {
              "id": 9183,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9180,
                  "indexed": true,
                  "name": "staker",
                  "nodeType": "VariableDeclaration",
                  "scope": 9184,
                  "src": "1608:22:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 9179,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "1608:7:29",
                    "stateMutability": "nonpayable",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9182,
                  "indexed": false,
                  "name": "daiValue",
                  "nodeType": "VariableDeclaration",
                  "scope": 9184,
                  "src": "1684:16:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9181,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "1684:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "1568:138:29"
            },
            "src": "1553:154:29"
          },
          {
            "anonymous": false,
            "documentation": null,
            "id": 9192,
            "name": "DAIStakeWithdraw",
            "nodeType": "EventDefinition",
            "parameters": {
              "id": 9191,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9186,
                  "indexed": true,
                  "name": "staker",
                  "nodeType": "VariableDeclaration",
                  "scope": 9192,
                  "src": "1841:22:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 9185,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "1841:7:29",
                    "stateMutability": "nonpayable",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9188,
                  "indexed": false,
                  "name": "daiValue",
                  "nodeType": "VariableDeclaration",
                  "scope": 9192,
                  "src": "1922:16:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9187,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "1922:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9190,
                  "indexed": false,
                  "name": "daiActual",
                  "nodeType": "VariableDeclaration",
                  "scope": 9192,
                  "src": "1997:17:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9189,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "1997:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "1784:236:29"
            },
            "src": "1762:259:29"
          },
          {
            "anonymous": false,
            "documentation": null,
            "id": 9202,
            "name": "InterestCollected",
            "nodeType": "EventDefinition",
            "parameters": {
              "id": 9201,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9194,
                  "indexed": false,
                  "name": "recipient",
                  "nodeType": "VariableDeclaration",
                  "scope": 9202,
                  "src": "2144:17:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 9193,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "2144:7:29",
                    "stateMutability": "nonpayable",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9196,
                  "indexed": false,
                  "name": "cdaiValue",
                  "nodeType": "VariableDeclaration",
                  "scope": 9202,
                  "src": "2225:17:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9195,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "2225:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9198,
                  "indexed": false,
                  "name": "daiValue",
                  "nodeType": "VariableDeclaration",
                  "scope": 9202,
                  "src": "2306:16:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9197,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "2306:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9200,
                  "indexed": false,
                  "name": "daiPrecisionLoss",
                  "nodeType": "VariableDeclaration",
                  "scope": 9202,
                  "src": "2389:24:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9199,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "2389:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "2094:325:29"
            },
            "src": "2071:349:29"
          },
          {
            "constant": false,
            "id": 9204,
            "name": "dai",
            "nodeType": "VariableDeclaration",
            "scope": 9740,
            "src": "2451:16:29",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_contract$_ERC20_$21849",
              "typeString": "contract ERC20"
            },
            "typeName": {
              "contractScope": null,
              "id": 9203,
              "name": "ERC20",
              "nodeType": "UserDefinedTypeName",
              "referencedDeclaration": 21849,
              "src": "2451:5:29",
              "typeDescriptions": {
                "typeIdentifier": "t_contract$_ERC20_$21849",
                "typeString": "contract ERC20"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 9206,
            "name": "cDai",
            "nodeType": "VariableDeclaration",
            "scope": 9740,
            "src": "2500:18:29",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_contract$_cERC20_$9160",
              "typeString": "contract cERC20"
            },
            "typeName": {
              "contractScope": null,
              "id": 9205,
              "name": "cERC20",
              "nodeType": "UserDefinedTypeName",
              "referencedDeclaration": 9160,
              "src": "2500:6:29",
              "typeDescriptions": {
                "typeIdentifier": "t_contract$_cERC20_$9160",
                "typeString": "contract cERC20"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 9208,
            "name": "blockInterval",
            "nodeType": "VariableDeclaration",
            "scope": 9740,
            "src": "2665:28:29",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_uint256",
              "typeString": "uint256"
            },
            "typeName": {
              "id": 9207,
              "name": "uint256",
              "nodeType": "ElementaryTypeName",
              "src": "2665:7:29",
              "typeDescriptions": {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 9210,
            "name": "lastUBICollection",
            "nodeType": "VariableDeclaration",
            "scope": 9740,
            "src": "2784:32:29",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_uint256",
              "typeString": "uint256"
            },
            "typeName": {
              "id": 9209,
              "name": "uint256",
              "nodeType": "ElementaryTypeName",
              "src": "2784:7:29",
              "typeDescriptions": {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 9213,
            "name": "totalStaked",
            "nodeType": "VariableDeclaration",
            "scope": 9740,
            "src": "2874:30:29",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_uint256",
              "typeString": "uint256"
            },
            "typeName": {
              "id": 9211,
              "name": "uint256",
              "nodeType": "ElementaryTypeName",
              "src": "2874:7:29",
              "typeDescriptions": {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              }
            },
            "value": {
              "argumentTypes": null,
              "hexValue": "30",
              "id": 9212,
              "isConstant": false,
              "isLValue": false,
              "isPure": true,
              "kind": "number",
              "lValueRequested": false,
              "nodeType": "Literal",
              "src": "2903:1:29",
              "subdenomination": null,
              "typeDescriptions": {
                "typeIdentifier": "t_rational_0_by_1",
                "typeString": "int_const 0"
              },
              "value": "0"
            },
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 9216,
            "name": "avgInterestDonatedRatio",
            "nodeType": "VariableDeclaration",
            "scope": 9740,
            "src": "3062:43:29",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_uint32",
              "typeString": "uint32"
            },
            "typeName": {
              "id": 9214,
              "name": "uint32",
              "nodeType": "ElementaryTypeName",
              "src": "3062:6:29",
              "typeDescriptions": {
                "typeIdentifier": "t_uint32",
                "typeString": "uint32"
              }
            },
            "value": {
              "argumentTypes": null,
              "hexValue": "316536",
              "id": 9215,
              "isConstant": false,
              "isLValue": false,
              "isPure": true,
              "kind": "number",
              "lValueRequested": false,
              "nodeType": "Literal",
              "src": "3102:3:29",
              "subdenomination": null,
              "typeDescriptions": {
                "typeIdentifier": "t_rational_1000000_by_1",
                "typeString": "int_const 1000000"
              },
              "value": "1e6"
            },
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 9218,
            "name": "fundManager",
            "nodeType": "VariableDeclaration",
            "scope": 9740,
            "src": "3160:26:29",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_address",
              "typeString": "address"
            },
            "typeName": {
              "id": 9217,
              "name": "address",
              "nodeType": "ElementaryTypeName",
              "src": "3160:7:29",
              "stateMutability": "nonpayable",
              "typeDescriptions": {
                "typeIdentifier": "t_address",
                "typeString": "address"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "body": {
              "id": 9229,
              "nodeType": "Block",
              "src": "3218:103:29",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "commonType": {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        },
                        "id": 9224,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "leftExpression": {
                          "argumentTypes": null,
                          "expression": {
                            "argumentTypes": null,
                            "id": 9221,
                            "name": "msg",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 22171,
                            "src": "3236:3:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_magic_message",
                              "typeString": "msg"
                            }
                          },
                          "id": 9222,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "memberName": "sender",
                          "nodeType": "MemberAccess",
                          "referencedDeclaration": null,
                          "src": "3236:10:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_address_payable",
                            "typeString": "address payable"
                          }
                        },
                        "nodeType": "BinaryOperation",
                        "operator": "==",
                        "rightExpression": {
                          "argumentTypes": null,
                          "id": 9223,
                          "name": "fundManager",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9218,
                          "src": "3250:11:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_address",
                            "typeString": "address"
                          }
                        },
                        "src": "3236:25:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "hexValue": "4f6e6c792046756e644d616e616765722063616e2063616c6c2074686973206d6574686f64",
                        "id": 9225,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "3263:39:29",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_8659903c14beb1decb5cde807aae2b42823801f7a2ec9f1cb2d42f84ff652fab",
                          "typeString": "literal_string \"Only FundManager can call this method\""
                        },
                        "value": "Only FundManager can call this method"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        {
                          "typeIdentifier": "t_stringliteral_8659903c14beb1decb5cde807aae2b42823801f7a2ec9f1cb2d42f84ff652fab",
                          "typeString": "literal_string \"Only FundManager can call this method\""
                        }
                      ],
                      "id": 9220,
                      "name": "require",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [
                        22174,
                        22175
                      ],
                      "referencedDeclaration": 22175,
                      "src": "3228:7:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                        "typeString": "function (bool,string memory) pure"
                      }
                    },
                    "id": 9226,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "3228:75:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 9227,
                  "nodeType": "ExpressionStatement",
                  "src": "3228:75:29"
                },
                {
                  "id": 9228,
                  "nodeType": "PlaceholderStatement",
                  "src": "3313:1:29"
                }
              ]
            },
            "documentation": null,
            "id": 9230,
            "name": "onlyFundManager",
            "nodeType": "ModifierDefinition",
            "parameters": {
              "id": 9219,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "3218:0:29"
            },
            "src": "3193:128:29",
            "visibility": "internal"
          },
          {
            "body": {
              "id": 9283,
              "nodeType": "Block",
              "src": "3933:294:29",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 9253,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 9249,
                      "name": "dai",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9204,
                      "src": "3943:3:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_contract$_ERC20_$21849",
                        "typeString": "contract ERC20"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 9251,
                          "name": "_dai",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9232,
                          "src": "3955:4:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_address",
                            "typeString": "address"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_address",
                            "typeString": "address"
                          }
                        ],
                        "id": 9250,
                        "name": "ERC20",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 21849,
                        "src": "3949:5:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_type$_t_contract$_ERC20_$21849_$",
                          "typeString": "type(contract ERC20)"
                        }
                      },
                      "id": 9252,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "typeConversion",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "3949:11:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_contract$_ERC20_$21849",
                        "typeString": "contract ERC20"
                      }
                    },
                    "src": "3943:17:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_contract$_ERC20_$21849",
                      "typeString": "contract ERC20"
                    }
                  },
                  "id": 9254,
                  "nodeType": "ExpressionStatement",
                  "src": "3943:17:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 9259,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 9255,
                      "name": "cDai",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9206,
                      "src": "3970:4:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_contract$_cERC20_$9160",
                        "typeString": "contract cERC20"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 9257,
                          "name": "_cDai",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9234,
                          "src": "3984:5:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_address",
                            "typeString": "address"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_address",
                            "typeString": "address"
                          }
                        ],
                        "id": 9256,
                        "name": "cERC20",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9160,
                        "src": "3977:6:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_type$_t_contract$_cERC20_$9160_$",
                          "typeString": "type(contract cERC20)"
                        }
                      },
                      "id": 9258,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "typeConversion",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "3977:13:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_contract$_cERC20_$9160",
                        "typeString": "contract cERC20"
                      }
                    },
                    "src": "3970:20:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_contract$_cERC20_$9160",
                      "typeString": "contract cERC20"
                    }
                  },
                  "id": 9260,
                  "nodeType": "ExpressionStatement",
                  "src": "3970:20:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 9263,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 9261,
                      "name": "blockInterval",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9208,
                      "src": "4000:13:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "id": 9262,
                      "name": "_blockInterval",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9238,
                      "src": "4016:14:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "4000:30:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 9264,
                  "nodeType": "ExpressionStatement",
                  "src": "4000:30:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 9271,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 9265,
                      "name": "lastUBICollection",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9210,
                      "src": "4040:17:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 9269,
                          "name": "blockInterval",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9208,
                          "src": "4077:13:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        ],
                        "expression": {
                          "argumentTypes": null,
                          "expression": {
                            "argumentTypes": null,
                            "id": 9266,
                            "name": "block",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 22161,
                            "src": "4060:5:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_magic_block",
                              "typeString": "block"
                            }
                          },
                          "id": 9267,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "memberName": "number",
                          "nodeType": "MemberAccess",
                          "referencedDeclaration": null,
                          "src": "4060:12:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "id": 9268,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "div",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 21239,
                        "src": "4060:16:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
                          "typeString": "function (uint256,uint256) pure returns (uint256)"
                        }
                      },
                      "id": 9270,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "functionCall",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "4060:31:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "4040:51:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 9272,
                  "nodeType": "ExpressionStatement",
                  "src": "4040:51:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 9275,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 9273,
                      "name": "fundManager",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9218,
                      "src": "4101:11:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "id": 9274,
                      "name": "_fundManager",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9236,
                      "src": "4115:12:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "src": "4101:26:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "id": 9276,
                  "nodeType": "ExpressionStatement",
                  "src": "4101:26:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "id": 9279,
                            "name": "avatar",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 1281,
                            "src": "4212:6:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_contract$_Avatar_$12705",
                              "typeString": "contract Avatar"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_contract$_Avatar_$12705",
                              "typeString": "contract Avatar"
                            }
                          ],
                          "id": 9278,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "lValueRequested": false,
                          "nodeType": "ElementaryTypeNameExpression",
                          "src": "4204:7:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_address_$",
                            "typeString": "type(address)"
                          },
                          "typeName": "address"
                        },
                        "id": 9280,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "typeConversion",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "4204:15:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_address_payable",
                          "typeString": "address payable"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_address_payable",
                          "typeString": "address payable"
                        }
                      ],
                      "id": 9277,
                      "name": "addPauser",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 20905,
                      "src": "4194:9:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$",
                        "typeString": "function (address)"
                      }
                    },
                    "id": 9281,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "4194:26:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 9282,
                  "nodeType": "ExpressionStatement",
                  "src": "4194:26:29"
                }
              ]
            },
            "documentation": "@dev Constructor\n@param _dai The address of DAI\n@param _cDai The address of cDAI\n@param _fundManager The address of the fund manager contract\n@param _blockInterval How many blocks should be passed before the next execution of `collectUBIInterest`\n@param _avatar The avatar of the DAO\n@param _identity The identity contract",
            "id": 9284,
            "implemented": true,
            "kind": "constructor",
            "modifiers": [
              {
                "arguments": [
                  {
                    "argumentTypes": null,
                    "id": 9245,
                    "name": "_identity",
                    "nodeType": "Identifier",
                    "overloadedDeclarations": [],
                    "referencedDeclaration": 9242,
                    "src": "3913:9:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_contract$_Identity_$2380",
                      "typeString": "contract Identity"
                    }
                  },
                  {
                    "argumentTypes": null,
                    "id": 9246,
                    "name": "_avatar",
                    "nodeType": "Identifier",
                    "overloadedDeclarations": [],
                    "referencedDeclaration": 9240,
                    "src": "3924:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_contract$_Avatar_$12705",
                      "typeString": "contract Avatar"
                    }
                  }
                ],
                "id": 9247,
                "modifierName": {
                  "argumentTypes": null,
                  "id": 9244,
                  "name": "FeelessScheme",
                  "nodeType": "Identifier",
                  "overloadedDeclarations": [],
                  "referencedDeclaration": 1227,
                  "src": "3899:13:29",
                  "typeDescriptions": {
                    "typeIdentifier": "t_type$_t_contract$_FeelessScheme_$1227_$",
                    "typeString": "type(contract FeelessScheme)"
                  }
                },
                "nodeType": "ModifierInvocation",
                "src": "3899:33:29"
              }
            ],
            "name": "",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9243,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9232,
                  "name": "_dai",
                  "nodeType": "VariableDeclaration",
                  "scope": 9284,
                  "src": "3736:12:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 9231,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "3736:7:29",
                    "stateMutability": "nonpayable",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9234,
                  "name": "_cDai",
                  "nodeType": "VariableDeclaration",
                  "scope": 9284,
                  "src": "3758:13:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 9233,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "3758:7:29",
                    "stateMutability": "nonpayable",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9236,
                  "name": "_fundManager",
                  "nodeType": "VariableDeclaration",
                  "scope": 9284,
                  "src": "3781:20:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 9235,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "3781:7:29",
                    "stateMutability": "nonpayable",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9238,
                  "name": "_blockInterval",
                  "nodeType": "VariableDeclaration",
                  "scope": 9284,
                  "src": "3811:22:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9237,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "3811:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9240,
                  "name": "_avatar",
                  "nodeType": "VariableDeclaration",
                  "scope": 9284,
                  "src": "3843:14:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_contract$_Avatar_$12705",
                    "typeString": "contract Avatar"
                  },
                  "typeName": {
                    "contractScope": null,
                    "id": 9239,
                    "name": "Avatar",
                    "nodeType": "UserDefinedTypeName",
                    "referencedDeclaration": 12705,
                    "src": "3843:6:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_contract$_Avatar_$12705",
                      "typeString": "contract Avatar"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9242,
                  "name": "_identity",
                  "nodeType": "VariableDeclaration",
                  "scope": 9284,
                  "src": "3867:18:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_contract$_Identity_$2380",
                    "typeString": "contract Identity"
                  },
                  "typeName": {
                    "contractScope": null,
                    "id": 9241,
                    "name": "Identity",
                    "nodeType": "UserDefinedTypeName",
                    "referencedDeclaration": 2380,
                    "src": "3867:8:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_contract$_Identity_$2380",
                      "typeString": "contract Identity"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "3726:165:29"
            },
            "returnParameters": {
              "id": 9248,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "3933:0:29"
            },
            "scope": 9740,
            "src": "3715:512:29",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "public"
          },
          {
            "body": {
              "id": 9295,
              "nodeType": "Block",
              "src": "4439:43:29",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 9293,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 9291,
                      "name": "fundManager",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9218,
                      "src": "4449:11:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "id": 9292,
                      "name": "_fundManager",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9286,
                      "src": "4463:12:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "src": "4449:26:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "id": 9294,
                  "nodeType": "ExpressionStatement",
                  "src": "4449:26:29"
                }
              ]
            },
            "documentation": "@dev Allows the DAO to change the fund manager contract address\n@param _fundManager Address of the new contract",
            "id": 9296,
            "implemented": true,
            "kind": "function",
            "modifiers": [
              {
                "arguments": null,
                "id": 9289,
                "modifierName": {
                  "argumentTypes": null,
                  "id": 9288,
                  "name": "onlyAvatar",
                  "nodeType": "Identifier",
                  "overloadedDeclarations": [],
                  "referencedDeclaration": 1325,
                  "src": "4428:10:29",
                  "typeDescriptions": {
                    "typeIdentifier": "t_modifier$__$",
                    "typeString": "modifier ()"
                  }
                },
                "nodeType": "ModifierInvocation",
                "src": "4428:10:29"
              }
            ],
            "name": "setFundManager",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9287,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9286,
                  "name": "_fundManager",
                  "nodeType": "VariableDeclaration",
                  "scope": 9296,
                  "src": "4399:20:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 9285,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "4399:7:29",
                    "stateMutability": "nonpayable",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "4398:22:29"
            },
            "returnParameters": {
              "id": 9290,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "4439:0:29"
            },
            "scope": 9740,
            "src": "4375:107:29",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "public"
          },
          {
            "body": {
              "id": 9390,
              "nodeType": "Block",
              "src": "4812:1025:29",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "commonType": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        },
                        "id": 9306,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "leftExpression": {
                          "argumentTypes": null,
                          "id": 9304,
                          "name": "_amount",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9298,
                          "src": "4830:7:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "nodeType": "BinaryOperation",
                        "operator": ">",
                        "rightExpression": {
                          "argumentTypes": null,
                          "hexValue": "30",
                          "id": 9305,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "kind": "number",
                          "lValueRequested": false,
                          "nodeType": "Literal",
                          "src": "4840:1:29",
                          "subdenomination": null,
                          "typeDescriptions": {
                            "typeIdentifier": "t_rational_0_by_1",
                            "typeString": "int_const 0"
                          },
                          "value": "0"
                        },
                        "src": "4830:11:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "hexValue": "596f75206e65656420746f207374616b65206120706f73697469766520746f6b656e20616d6f756e74",
                        "id": 9307,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "4843:43:29",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_0df2c7e58c395cb8df3c21ef84be33d1d8ff5cbf2a8b2cf1fa7931eeed13da62",
                          "typeString": "literal_string \"You need to stake a positive token amount\""
                        },
                        "value": "You need to stake a positive token amount"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        {
                          "typeIdentifier": "t_stringliteral_0df2c7e58c395cb8df3c21ef84be33d1d8ff5cbf2a8b2cf1fa7931eeed13da62",
                          "typeString": "literal_string \"You need to stake a positive token amount\""
                        }
                      ],
                      "id": 9303,
                      "name": "require",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [
                        22174,
                        22175
                      ],
                      "referencedDeclaration": 22175,
                      "src": "4822:7:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                        "typeString": "function (bool,string memory) pure"
                      }
                    },
                    "id": 9308,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "4822:65:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 9309,
                  "nodeType": "ExpressionStatement",
                  "src": "4822:65:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "commonType": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        "id": 9321,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "leftExpression": {
                          "argumentTypes": null,
                          "arguments": [
                            {
                              "argumentTypes": null,
                              "expression": {
                                "argumentTypes": null,
                                "id": 9313,
                                "name": "msg",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 22171,
                                "src": "4935:3:29",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_magic_message",
                                  "typeString": "msg"
                                }
                              },
                              "id": 9314,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "lValueRequested": false,
                              "memberName": "sender",
                              "nodeType": "MemberAccess",
                              "referencedDeclaration": null,
                              "src": "4935:10:29",
                              "typeDescriptions": {
                                "typeIdentifier": "t_address_payable",
                                "typeString": "address payable"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "arguments": [
                                {
                                  "argumentTypes": null,
                                  "id": 9316,
                                  "name": "this",
                                  "nodeType": "Identifier",
                                  "overloadedDeclarations": [],
                                  "referencedDeclaration": 22327,
                                  "src": "4955:4:29",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_contract$_SimpleDAIStaking_$9740",
                                    "typeString": "contract SimpleDAIStaking"
                                  }
                                }
                              ],
                              "expression": {
                                "argumentTypes": [
                                  {
                                    "typeIdentifier": "t_contract$_SimpleDAIStaking_$9740",
                                    "typeString": "contract SimpleDAIStaking"
                                  }
                                ],
                                "id": 9315,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": true,
                                "lValueRequested": false,
                                "nodeType": "ElementaryTypeNameExpression",
                                "src": "4947:7:29",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_type$_t_address_$",
                                  "typeString": "type(address)"
                                },
                                "typeName": "address"
                              },
                              "id": 9317,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "kind": "typeConversion",
                              "lValueRequested": false,
                              "names": [],
                              "nodeType": "FunctionCall",
                              "src": "4947:13:29",
                              "typeDescriptions": {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "id": 9318,
                              "name": "_amount",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 9298,
                              "src": "4962:7:29",
                              "typeDescriptions": {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              }
                            }
                          ],
                          "expression": {
                            "argumentTypes": [
                              {
                                "typeIdentifier": "t_address_payable",
                                "typeString": "address payable"
                              },
                              {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              },
                              {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              }
                            ],
                            "expression": {
                              "argumentTypes": null,
                              "id": 9311,
                              "name": "dai",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 9204,
                              "src": "4918:3:29",
                              "typeDescriptions": {
                                "typeIdentifier": "t_contract$_ERC20_$21849",
                                "typeString": "contract ERC20"
                              }
                            },
                            "id": 9312,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": false,
                            "lValueRequested": false,
                            "memberName": "transferFrom",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": 21578,
                            "src": "4918:16:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$_t_bool_$",
                              "typeString": "function (address,address,uint256) external returns (bool)"
                            }
                          },
                          "id": 9319,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "kind": "functionCall",
                          "lValueRequested": false,
                          "names": [],
                          "nodeType": "FunctionCall",
                          "src": "4918:52:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_bool",
                            "typeString": "bool"
                          }
                        },
                        "nodeType": "BinaryOperation",
                        "operator": "==",
                        "rightExpression": {
                          "argumentTypes": null,
                          "hexValue": "74727565",
                          "id": 9320,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "kind": "bool",
                          "lValueRequested": false,
                          "nodeType": "Literal",
                          "src": "4974:4:29",
                          "subdenomination": null,
                          "typeDescriptions": {
                            "typeIdentifier": "t_bool",
                            "typeString": "bool"
                          },
                          "value": "true"
                        },
                        "src": "4918:60:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "hexValue": "7472616e7366657246726f6d206661696c65642c206d616b65207375726520796f7520617070726f76656420444149207472616e73666572",
                        "id": 9322,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "4992:58:29",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_ee07915d88e147dbd0474d1f4b7dd5b98a6778f07e832106ffd695a46b406d6e",
                          "typeString": "literal_string \"transferFrom failed, make sure you approved DAI transfer\""
                        },
                        "value": "transferFrom failed, make sure you approved DAI transfer"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        {
                          "typeIdentifier": "t_stringliteral_ee07915d88e147dbd0474d1f4b7dd5b98a6778f07e832106ffd695a46b406d6e",
                          "typeString": "literal_string \"transferFrom failed, make sure you approved DAI transfer\""
                        }
                      ],
                      "id": 9310,
                      "name": "require",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [
                        22174,
                        22175
                      ],
                      "referencedDeclaration": 22175,
                      "src": "4897:7:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                        "typeString": "function (bool,string memory) pure"
                      }
                    },
                    "id": 9323,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "4897:163:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 9324,
                  "nodeType": "ExpressionStatement",
                  "src": "4897:163:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "id": 9329,
                            "name": "cDai",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 9206,
                            "src": "5131:4:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_contract$_cERC20_$9160",
                              "typeString": "contract cERC20"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_contract$_cERC20_$9160",
                              "typeString": "contract cERC20"
                            }
                          ],
                          "id": 9328,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "lValueRequested": false,
                          "nodeType": "ElementaryTypeNameExpression",
                          "src": "5123:7:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_address_$",
                            "typeString": "type(address)"
                          },
                          "typeName": "address"
                        },
                        "id": 9330,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "typeConversion",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "5123:13:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 9331,
                        "name": "_amount",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9298,
                        "src": "5138:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        },
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      ],
                      "expression": {
                        "argumentTypes": null,
                        "id": 9325,
                        "name": "dai",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9204,
                        "src": "5111:3:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_contract$_ERC20_$21849",
                          "typeString": "contract ERC20"
                        }
                      },
                      "id": 9327,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "approve",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 21529,
                      "src": "5111:11:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$",
                        "typeString": "function (address,uint256) external returns (bool)"
                      }
                    },
                    "id": 9332,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "5111:35:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "id": 9333,
                  "nodeType": "ExpressionStatement",
                  "src": "5111:35:29"
                },
                {
                  "assignments": [
                    9335
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 9335,
                      "name": "res",
                      "nodeType": "VariableDeclaration",
                      "scope": 9390,
                      "src": "5181:11:29",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 9334,
                        "name": "uint256",
                        "nodeType": "ElementaryTypeName",
                        "src": "5181:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 9340,
                  "initialValue": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "id": 9338,
                        "name": "_amount",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9298,
                        "src": "5205:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      ],
                      "expression": {
                        "argumentTypes": null,
                        "id": 9336,
                        "name": "cDai",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9206,
                        "src": "5195:4:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_contract$_cERC20_$9160",
                          "typeString": "contract cERC20"
                        }
                      },
                      "id": 9337,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "mint",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 9126,
                      "src": "5195:9:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_external_nonpayable$_t_uint256_$returns$_t_uint256_$",
                        "typeString": "function (uint256) external returns (uint256)"
                      }
                    },
                    "id": 9339,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "5195:18:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "5181:32:29"
                },
                {
                  "condition": {
                    "argumentTypes": null,
                    "commonType": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    },
                    "id": 9343,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftExpression": {
                      "argumentTypes": null,
                      "id": 9341,
                      "name": "res",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9335,
                      "src": "5402:3:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "BinaryOperation",
                    "operator": ">",
                    "rightExpression": {
                      "argumentTypes": null,
                      "hexValue": "30",
                      "id": 9342,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": true,
                      "kind": "number",
                      "lValueRequested": false,
                      "nodeType": "Literal",
                      "src": "5408:1:29",
                      "subdenomination": null,
                      "typeDescriptions": {
                        "typeIdentifier": "t_rational_0_by_1",
                        "typeString": "int_const 0"
                      },
                      "value": "0"
                    },
                    "src": "5402:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "falseBody": null,
                  "id": 9352,
                  "nodeType": "IfStatement",
                  "src": "5398:94:29",
                  "trueBody": {
                    "id": 9351,
                    "nodeType": "Block",
                    "src": "5411:81:29",
                    "statements": [
                      {
                        "expression": {
                          "argumentTypes": null,
                          "arguments": [
                            {
                              "argumentTypes": null,
                              "commonType": {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              },
                              "id": 9347,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "lValueRequested": false,
                              "leftExpression": {
                                "argumentTypes": null,
                                "id": 9345,
                                "name": "res",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 9335,
                                "src": "5433:3:29",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_uint256",
                                  "typeString": "uint256"
                                }
                              },
                              "nodeType": "BinaryOperation",
                              "operator": "==",
                              "rightExpression": {
                                "argumentTypes": null,
                                "hexValue": "30",
                                "id": 9346,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": true,
                                "kind": "number",
                                "lValueRequested": false,
                                "nodeType": "Literal",
                                "src": "5440:1:29",
                                "subdenomination": null,
                                "typeDescriptions": {
                                  "typeIdentifier": "t_rational_0_by_1",
                                  "typeString": "int_const 0"
                                },
                                "value": "0"
                              },
                              "src": "5433:8:29",
                              "typeDescriptions": {
                                "typeIdentifier": "t_bool",
                                "typeString": "bool"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "hexValue": "4d696e74696e672063446169206661696c65642c2066756e64732072657475726e6564",
                              "id": 9348,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": true,
                              "kind": "string",
                              "lValueRequested": false,
                              "nodeType": "Literal",
                              "src": "5443:37:29",
                              "subdenomination": null,
                              "typeDescriptions": {
                                "typeIdentifier": "t_stringliteral_9fba825e72dafc705b289a19c5027021048dd7f2ebe3c823d265b59e8a41b98f",
                                "typeString": "literal_string \"Minting cDai failed, funds returned\""
                              },
                              "value": "Minting cDai failed, funds returned"
                            }
                          ],
                          "expression": {
                            "argumentTypes": [
                              {
                                "typeIdentifier": "t_bool",
                                "typeString": "bool"
                              },
                              {
                                "typeIdentifier": "t_stringliteral_9fba825e72dafc705b289a19c5027021048dd7f2ebe3c823d265b59e8a41b98f",
                                "typeString": "literal_string \"Minting cDai failed, funds returned\""
                              }
                            ],
                            "id": 9344,
                            "name": "require",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [
                              22174,
                              22175
                            ],
                            "referencedDeclaration": 22175,
                            "src": "5425:7:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                              "typeString": "function (bool,string memory) pure"
                            }
                          },
                          "id": 9349,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "kind": "functionCall",
                          "lValueRequested": false,
                          "names": [],
                          "nodeType": "FunctionCall",
                          "src": "5425:56:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_tuple$__$",
                            "typeString": "tuple()"
                          }
                        },
                        "id": 9350,
                        "nodeType": "ExpressionStatement",
                        "src": "5425:56:29"
                      }
                    ]
                  }
                },
                {
                  "assignments": [
                    9354
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 9354,
                      "name": "staker",
                      "nodeType": "VariableDeclaration",
                      "scope": 9390,
                      "src": "5539:21:29",
                      "stateVariable": false,
                      "storageLocation": "storage",
                      "typeDescriptions": {
                        "typeIdentifier": "t_struct$_Staker_$9174_storage_ptr",
                        "typeString": "struct SimpleDAIStaking.Staker"
                      },
                      "typeName": {
                        "contractScope": null,
                        "id": 9353,
                        "name": "Staker",
                        "nodeType": "UserDefinedTypeName",
                        "referencedDeclaration": 9174,
                        "src": "5539:6:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_struct$_Staker_$9174_storage_ptr",
                          "typeString": "struct SimpleDAIStaking.Staker"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 9359,
                  "initialValue": {
                    "argumentTypes": null,
                    "baseExpression": {
                      "argumentTypes": null,
                      "id": 9355,
                      "name": "stakers",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9178,
                      "src": "5563:7:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_mapping$_t_address_$_t_struct$_Staker_$9174_storage_$",
                        "typeString": "mapping(address => struct SimpleDAIStaking.Staker storage ref)"
                      }
                    },
                    "id": 9358,
                    "indexExpression": {
                      "argumentTypes": null,
                      "expression": {
                        "argumentTypes": null,
                        "id": 9356,
                        "name": "msg",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 22171,
                        "src": "5571:3:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_magic_message",
                          "typeString": "msg"
                        }
                      },
                      "id": 9357,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "sender",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": null,
                      "src": "5571:10:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address_payable",
                        "typeString": "address payable"
                      }
                    },
                    "isConstant": false,
                    "isLValue": true,
                    "isPure": false,
                    "lValueRequested": false,
                    "nodeType": "IndexAccess",
                    "src": "5563:19:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_struct$_Staker_$9174_storage",
                      "typeString": "struct SimpleDAIStaking.Staker storage ref"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "5539:43:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 9368,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "expression": {
                        "argumentTypes": null,
                        "id": 9360,
                        "name": "staker",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9354,
                        "src": "5592:6:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_struct$_Staker_$9174_storage_ptr",
                          "typeString": "struct SimpleDAIStaking.Staker storage pointer"
                        }
                      },
                      "id": 9362,
                      "isConstant": false,
                      "isLValue": true,
                      "isPure": false,
                      "lValueRequested": true,
                      "memberName": "stakedDAI",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 9171,
                      "src": "5592:16:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 9366,
                          "name": "_amount",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9298,
                          "src": "5632:7:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        ],
                        "expression": {
                          "argumentTypes": null,
                          "expression": {
                            "argumentTypes": null,
                            "id": 9363,
                            "name": "staker",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 9354,
                            "src": "5611:6:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_struct$_Staker_$9174_storage_ptr",
                              "typeString": "struct SimpleDAIStaking.Staker storage pointer"
                            }
                          },
                          "id": 9364,
                          "isConstant": false,
                          "isLValue": true,
                          "isPure": false,
                          "lValueRequested": false,
                          "memberName": "stakedDAI",
                          "nodeType": "MemberAccess",
                          "referencedDeclaration": 9171,
                          "src": "5611:16:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "id": 9365,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "add",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 21287,
                        "src": "5611:20:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
                          "typeString": "function (uint256,uint256) pure returns (uint256)"
                        }
                      },
                      "id": 9367,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "functionCall",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "5611:29:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "5592:48:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 9369,
                  "nodeType": "ExpressionStatement",
                  "src": "5592:48:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 9375,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "expression": {
                        "argumentTypes": null,
                        "id": 9370,
                        "name": "staker",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9354,
                        "src": "5650:6:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_struct$_Staker_$9174_storage_ptr",
                          "typeString": "struct SimpleDAIStaking.Staker storage pointer"
                        }
                      },
                      "id": 9372,
                      "isConstant": false,
                      "isLValue": true,
                      "isPure": false,
                      "lValueRequested": true,
                      "memberName": "lastStake",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 9173,
                      "src": "5650:16:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "expression": {
                        "argumentTypes": null,
                        "id": 9373,
                        "name": "block",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 22161,
                        "src": "5669:5:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_magic_block",
                          "typeString": "block"
                        }
                      },
                      "id": 9374,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "number",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": null,
                      "src": "5669:12:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "5650:31:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 9376,
                  "nodeType": "ExpressionStatement",
                  "src": "5650:31:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 9382,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 9377,
                      "name": "totalStaked",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9213,
                      "src": "5746:11:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 9380,
                          "name": "_amount",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9298,
                          "src": "5776:7:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        ],
                        "expression": {
                          "argumentTypes": null,
                          "id": 9378,
                          "name": "totalStaked",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9213,
                          "src": "5760:11:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "id": 9379,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "add",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 21287,
                        "src": "5760:15:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
                          "typeString": "function (uint256,uint256) pure returns (uint256)"
                        }
                      },
                      "id": 9381,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "functionCall",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "5760:24:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "5746:38:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 9383,
                  "nodeType": "ExpressionStatement",
                  "src": "5746:38:29"
                },
                {
                  "eventCall": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "expression": {
                          "argumentTypes": null,
                          "id": 9385,
                          "name": "msg",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 22171,
                          "src": "5810:3:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_magic_message",
                            "typeString": "msg"
                          }
                        },
                        "id": 9386,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "sender",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": null,
                        "src": "5810:10:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_address_payable",
                          "typeString": "address payable"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 9387,
                        "name": "_amount",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9298,
                        "src": "5822:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_address_payable",
                          "typeString": "address payable"
                        },
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      ],
                      "id": 9384,
                      "name": "DAIStaked",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9184,
                      "src": "5800:9:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$returns$__$",
                        "typeString": "function (address,uint256)"
                      }
                    },
                    "id": 9388,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "5800:30:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 9389,
                  "nodeType": "EmitStatement",
                  "src": "5795:35:29"
                }
              ]
            },
            "documentation": "@dev Allows a staker to deposit DAI tokens. Notice that `approve` is\nneeded to be executed before the execution of this method.\nCan be executed only when the contract is not paused.\n@param _amount The amount of DAI to stake",
            "id": 9391,
            "implemented": true,
            "kind": "function",
            "modifiers": [
              {
                "arguments": null,
                "id": 9301,
                "modifierName": {
                  "argumentTypes": null,
                  "id": 9300,
                  "name": "whenNotPaused",
                  "nodeType": "Identifier",
                  "overloadedDeclarations": [],
                  "referencedDeclaration": 21068,
                  "src": "4798:13:29",
                  "typeDescriptions": {
                    "typeIdentifier": "t_modifier$__$",
                    "typeString": "modifier ()"
                  }
                },
                "nodeType": "ModifierInvocation",
                "src": "4798:13:29"
              }
            ],
            "name": "stakeDAI",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9299,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9298,
                  "name": "_amount",
                  "nodeType": "VariableDeclaration",
                  "scope": 9391,
                  "src": "4774:15:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9297,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "4774:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "4773:17:29"
            },
            "returnParameters": {
              "id": 9302,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "4812:0:29"
            },
            "scope": 9740,
            "src": "4756:1081:29",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "public"
          },
          {
            "body": {
              "id": 9473,
              "nodeType": "Block",
              "src": "5936:853:29",
              "statements": [
                {
                  "assignments": [
                    9395
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 9395,
                      "name": "staker",
                      "nodeType": "VariableDeclaration",
                      "scope": 9473,
                      "src": "5946:21:29",
                      "stateVariable": false,
                      "storageLocation": "storage",
                      "typeDescriptions": {
                        "typeIdentifier": "t_struct$_Staker_$9174_storage_ptr",
                        "typeString": "struct SimpleDAIStaking.Staker"
                      },
                      "typeName": {
                        "contractScope": null,
                        "id": 9394,
                        "name": "Staker",
                        "nodeType": "UserDefinedTypeName",
                        "referencedDeclaration": 9174,
                        "src": "5946:6:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_struct$_Staker_$9174_storage_ptr",
                          "typeString": "struct SimpleDAIStaking.Staker"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 9400,
                  "initialValue": {
                    "argumentTypes": null,
                    "baseExpression": {
                      "argumentTypes": null,
                      "id": 9396,
                      "name": "stakers",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9178,
                      "src": "5970:7:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_mapping$_t_address_$_t_struct$_Staker_$9174_storage_$",
                        "typeString": "mapping(address => struct SimpleDAIStaking.Staker storage ref)"
                      }
                    },
                    "id": 9399,
                    "indexExpression": {
                      "argumentTypes": null,
                      "expression": {
                        "argumentTypes": null,
                        "id": 9397,
                        "name": "msg",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 22171,
                        "src": "5978:3:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_magic_message",
                          "typeString": "msg"
                        }
                      },
                      "id": 9398,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "sender",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": null,
                      "src": "5978:10:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address_payable",
                        "typeString": "address payable"
                      }
                    },
                    "isConstant": false,
                    "isLValue": true,
                    "isPure": false,
                    "lValueRequested": false,
                    "nodeType": "IndexAccess",
                    "src": "5970:19:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_struct$_Staker_$9174_storage",
                      "typeString": "struct SimpleDAIStaking.Staker storage ref"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "5946:43:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "commonType": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        },
                        "id": 9405,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "leftExpression": {
                          "argumentTypes": null,
                          "expression": {
                            "argumentTypes": null,
                            "id": 9402,
                            "name": "staker",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 9395,
                            "src": "6007:6:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_struct$_Staker_$9174_storage_ptr",
                              "typeString": "struct SimpleDAIStaking.Staker storage pointer"
                            }
                          },
                          "id": 9403,
                          "isConstant": false,
                          "isLValue": true,
                          "isPure": false,
                          "lValueRequested": false,
                          "memberName": "stakedDAI",
                          "nodeType": "MemberAccess",
                          "referencedDeclaration": 9171,
                          "src": "6007:16:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "nodeType": "BinaryOperation",
                        "operator": ">",
                        "rightExpression": {
                          "argumentTypes": null,
                          "hexValue": "30",
                          "id": 9404,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "kind": "number",
                          "lValueRequested": false,
                          "nodeType": "Literal",
                          "src": "6026:1:29",
                          "subdenomination": null,
                          "typeDescriptions": {
                            "typeIdentifier": "t_rational_0_by_1",
                            "typeString": "int_const 0"
                          },
                          "value": "0"
                        },
                        "src": "6007:20:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "hexValue": "4e6f20444149207374616b6564",
                        "id": 9406,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "6029:15:29",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_c7a1c4dcae14020a6de4ccb28b8861c795f9958e1fbdb2ab0fb5dc5d25e10738",
                          "typeString": "literal_string \"No DAI staked\""
                        },
                        "value": "No DAI staked"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        {
                          "typeIdentifier": "t_stringliteral_c7a1c4dcae14020a6de4ccb28b8861c795f9958e1fbdb2ab0fb5dc5d25e10738",
                          "typeString": "literal_string \"No DAI staked\""
                        }
                      ],
                      "id": 9401,
                      "name": "require",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [
                        22174,
                        22175
                      ],
                      "referencedDeclaration": 22175,
                      "src": "5999:7:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                        "typeString": "function (bool,string memory) pure"
                      }
                    },
                    "id": 9407,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "5999:46:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 9408,
                  "nodeType": "ExpressionStatement",
                  "src": "5999:46:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "commonType": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        },
                        "id": 9416,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "leftExpression": {
                          "argumentTypes": null,
                          "arguments": [
                            {
                              "argumentTypes": null,
                              "expression": {
                                "argumentTypes": null,
                                "id": 9412,
                                "name": "staker",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 9395,
                                "src": "6085:6:29",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_struct$_Staker_$9174_storage_ptr",
                                  "typeString": "struct SimpleDAIStaking.Staker storage pointer"
                                }
                              },
                              "id": 9413,
                              "isConstant": false,
                              "isLValue": true,
                              "isPure": false,
                              "lValueRequested": false,
                              "memberName": "stakedDAI",
                              "nodeType": "MemberAccess",
                              "referencedDeclaration": 9171,
                              "src": "6085:16:29",
                              "typeDescriptions": {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              }
                            }
                          ],
                          "expression": {
                            "argumentTypes": [
                              {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              }
                            ],
                            "expression": {
                              "argumentTypes": null,
                              "id": 9410,
                              "name": "cDai",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 9206,
                              "src": "6063:4:29",
                              "typeDescriptions": {
                                "typeIdentifier": "t_contract$_cERC20_$9160",
                                "typeString": "contract cERC20"
                              }
                            },
                            "id": 9411,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": false,
                            "lValueRequested": false,
                            "memberName": "redeemUnderlying",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": 9133,
                            "src": "6063:21:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_function_external_nonpayable$_t_uint256_$returns$_t_uint256_$",
                              "typeString": "function (uint256) external returns (uint256)"
                            }
                          },
                          "id": 9414,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "kind": "functionCall",
                          "lValueRequested": false,
                          "names": [],
                          "nodeType": "FunctionCall",
                          "src": "6063:39:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "nodeType": "BinaryOperation",
                        "operator": "==",
                        "rightExpression": {
                          "argumentTypes": null,
                          "hexValue": "30",
                          "id": 9415,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "kind": "number",
                          "lValueRequested": false,
                          "nodeType": "Literal",
                          "src": "6106:1:29",
                          "subdenomination": null,
                          "typeDescriptions": {
                            "typeIdentifier": "t_rational_0_by_1",
                            "typeString": "int_const 0"
                          },
                          "value": "0"
                        },
                        "src": "6063:44:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "hexValue": "4661696c656420746f2072656465656d2063446169",
                        "id": 9417,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "6109:23:29",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_1f647a2f625cf3b1ea4c7844befd4fe6574e2c7464224cfadaec07f3918cd8a2",
                          "typeString": "literal_string \"Failed to redeem cDai\""
                        },
                        "value": "Failed to redeem cDai"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        {
                          "typeIdentifier": "t_stringliteral_1f647a2f625cf3b1ea4c7844befd4fe6574e2c7464224cfadaec07f3918cd8a2",
                          "typeString": "literal_string \"Failed to redeem cDai\""
                        }
                      ],
                      "id": 9409,
                      "name": "require",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [
                        22174,
                        22175
                      ],
                      "referencedDeclaration": 22175,
                      "src": "6055:7:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                        "typeString": "function (bool,string memory) pure"
                      }
                    },
                    "id": 9418,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "6055:78:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 9419,
                  "nodeType": "ExpressionStatement",
                  "src": "6055:78:29"
                },
                {
                  "assignments": [
                    9421
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 9421,
                      "name": "daiWithdraw",
                      "nodeType": "VariableDeclaration",
                      "scope": 9473,
                      "src": "6143:19:29",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 9420,
                        "name": "uint256",
                        "nodeType": "ElementaryTypeName",
                        "src": "6143:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 9424,
                  "initialValue": {
                    "argumentTypes": null,
                    "expression": {
                      "argumentTypes": null,
                      "id": 9422,
                      "name": "staker",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9395,
                      "src": "6165:6:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_struct$_Staker_$9174_storage_ptr",
                        "typeString": "struct SimpleDAIStaking.Staker storage pointer"
                      }
                    },
                    "id": 9423,
                    "isConstant": false,
                    "isLValue": true,
                    "isPure": false,
                    "lValueRequested": false,
                    "memberName": "stakedDAI",
                    "nodeType": "MemberAccess",
                    "referencedDeclaration": 9171,
                    "src": "6165:16:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "6143:38:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 9429,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "expression": {
                        "argumentTypes": null,
                        "id": 9425,
                        "name": "staker",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9395,
                        "src": "6255:6:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_struct$_Staker_$9174_storage_ptr",
                          "typeString": "struct SimpleDAIStaking.Staker storage pointer"
                        }
                      },
                      "id": 9427,
                      "isConstant": false,
                      "isLValue": true,
                      "isPure": false,
                      "lValueRequested": true,
                      "memberName": "stakedDAI",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 9171,
                      "src": "6255:16:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "hexValue": "30",
                      "id": 9428,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": true,
                      "kind": "number",
                      "lValueRequested": false,
                      "nodeType": "Literal",
                      "src": "6274:1:29",
                      "subdenomination": null,
                      "typeDescriptions": {
                        "typeIdentifier": "t_rational_0_by_1",
                        "typeString": "int_const 0"
                      },
                      "value": "0"
                    },
                    "src": "6255:20:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 9430,
                  "nodeType": "ExpressionStatement",
                  "src": "6255:20:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 9436,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 9431,
                      "name": "totalStaked",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9213,
                      "src": "6286:11:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 9434,
                          "name": "daiWithdraw",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9421,
                          "src": "6316:11:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        ],
                        "expression": {
                          "argumentTypes": null,
                          "id": 9432,
                          "name": "totalStaked",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9213,
                          "src": "6300:11:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "id": 9433,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "sub",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 21263,
                        "src": "6300:15:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
                          "typeString": "function (uint256,uint256) pure returns (uint256)"
                        }
                      },
                      "id": 9435,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "functionCall",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "6300:28:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "6286:42:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 9437,
                  "nodeType": "ExpressionStatement",
                  "src": "6286:42:29"
                },
                {
                  "assignments": [
                    9439
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 9439,
                      "name": "daiActual",
                      "nodeType": "VariableDeclaration",
                      "scope": 9473,
                      "src": "6497:17:29",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 9438,
                        "name": "uint256",
                        "nodeType": "ElementaryTypeName",
                        "src": "6497:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 9446,
                  "initialValue": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "id": 9443,
                            "name": "this",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 22327,
                            "src": "6539:4:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_contract$_SimpleDAIStaking_$9740",
                              "typeString": "contract SimpleDAIStaking"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_contract$_SimpleDAIStaking_$9740",
                              "typeString": "contract SimpleDAIStaking"
                            }
                          ],
                          "id": 9442,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "lValueRequested": false,
                          "nodeType": "ElementaryTypeNameExpression",
                          "src": "6531:7:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_address_$",
                            "typeString": "type(address)"
                          },
                          "typeName": "address"
                        },
                        "id": 9444,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "typeConversion",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "6531:13:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      ],
                      "expression": {
                        "argumentTypes": null,
                        "id": 9440,
                        "name": "dai",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9204,
                        "src": "6517:3:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_contract$_ERC20_$21849",
                          "typeString": "contract ERC20"
                        }
                      },
                      "id": 9441,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "balanceOf",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 21458,
                      "src": "6517:13:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$",
                        "typeString": "function (address) view external returns (uint256)"
                      }
                    },
                    "id": 9445,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "6517:28:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "6497:48:29"
                },
                {
                  "condition": {
                    "argumentTypes": null,
                    "commonType": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    },
                    "id": 9449,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftExpression": {
                      "argumentTypes": null,
                      "id": 9447,
                      "name": "daiActual",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9439,
                      "src": "6559:9:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "BinaryOperation",
                    "operator": "<",
                    "rightExpression": {
                      "argumentTypes": null,
                      "id": 9448,
                      "name": "daiWithdraw",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9421,
                      "src": "6571:11:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "6559:23:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "falseBody": null,
                  "id": 9455,
                  "nodeType": "IfStatement",
                  "src": "6555:77:29",
                  "trueBody": {
                    "id": 9454,
                    "nodeType": "Block",
                    "src": "6584:48:29",
                    "statements": [
                      {
                        "expression": {
                          "argumentTypes": null,
                          "id": 9452,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "leftHandSide": {
                            "argumentTypes": null,
                            "id": 9450,
                            "name": "daiWithdraw",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 9421,
                            "src": "6598:11:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          },
                          "nodeType": "Assignment",
                          "operator": "=",
                          "rightHandSide": {
                            "argumentTypes": null,
                            "id": 9451,
                            "name": "daiActual",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 9439,
                            "src": "6612:9:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          },
                          "src": "6598:23:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "id": 9453,
                        "nodeType": "ExpressionStatement",
                        "src": "6598:23:29"
                      }
                    ]
                  }
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "expression": {
                              "argumentTypes": null,
                              "id": 9459,
                              "name": "msg",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 22171,
                              "src": "6662:3:29",
                              "typeDescriptions": {
                                "typeIdentifier": "t_magic_message",
                                "typeString": "msg"
                              }
                            },
                            "id": 9460,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": false,
                            "lValueRequested": false,
                            "memberName": "sender",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": null,
                            "src": "6662:10:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_address_payable",
                              "typeString": "address payable"
                            }
                          },
                          {
                            "argumentTypes": null,
                            "id": 9461,
                            "name": "daiWithdraw",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 9421,
                            "src": "6674:11:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_address_payable",
                              "typeString": "address payable"
                            },
                            {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          ],
                          "expression": {
                            "argumentTypes": null,
                            "id": 9457,
                            "name": "dai",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 9204,
                            "src": "6649:3:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_contract$_ERC20_$21849",
                              "typeString": "contract ERC20"
                            }
                          },
                          "id": 9458,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "memberName": "transfer",
                          "nodeType": "MemberAccess",
                          "referencedDeclaration": 21493,
                          "src": "6649:12:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$",
                            "typeString": "function (address,uint256) external returns (bool)"
                          }
                        },
                        "id": 9462,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "functionCall",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "6649:37:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "hexValue": "7769746864726177207472616e73666572206661696c6564",
                        "id": 9463,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "6688:26:29",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_58bc929e474c8aeb2e4ca83613053e225f521e498e8deece823d1749bab458d1",
                          "typeString": "literal_string \"withdraw transfer failed\""
                        },
                        "value": "withdraw transfer failed"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        {
                          "typeIdentifier": "t_stringliteral_58bc929e474c8aeb2e4ca83613053e225f521e498e8deece823d1749bab458d1",
                          "typeString": "literal_string \"withdraw transfer failed\""
                        }
                      ],
                      "id": 9456,
                      "name": "require",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [
                        22174,
                        22175
                      ],
                      "referencedDeclaration": 22175,
                      "src": "6641:7:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                        "typeString": "function (bool,string memory) pure"
                      }
                    },
                    "id": 9464,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "6641:74:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 9465,
                  "nodeType": "ExpressionStatement",
                  "src": "6641:74:29"
                },
                {
                  "eventCall": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "expression": {
                          "argumentTypes": null,
                          "id": 9467,
                          "name": "msg",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 22171,
                          "src": "6747:3:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_magic_message",
                            "typeString": "msg"
                          }
                        },
                        "id": 9468,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "sender",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": null,
                        "src": "6747:10:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_address_payable",
                          "typeString": "address payable"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 9469,
                        "name": "daiWithdraw",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9421,
                        "src": "6759:11:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 9470,
                        "name": "daiActual",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9439,
                        "src": "6772:9:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_address_payable",
                          "typeString": "address payable"
                        },
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        },
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      ],
                      "id": 9466,
                      "name": "DAIStakeWithdraw",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9192,
                      "src": "6730:16:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$returns$__$",
                        "typeString": "function (address,uint256,uint256)"
                      }
                    },
                    "id": 9471,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "6730:52:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 9472,
                  "nodeType": "EmitStatement",
                  "src": "6725:57:29"
                }
              ]
            },
            "documentation": "@dev Withdraws the sender staked DAI.",
            "id": 9474,
            "implemented": true,
            "kind": "function",
            "modifiers": [],
            "name": "withdrawStake",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9392,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "5926:2:29"
            },
            "returnParameters": {
              "id": 9393,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "5936:0:29"
            },
            "scope": 9740,
            "src": "5904:885:29",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "public"
          },
          {
            "body": {
              "id": 9505,
              "nodeType": "Block",
              "src": "6977:258:29",
              "statements": [
                {
                  "assignments": [
                    9480
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 9480,
                      "name": "er",
                      "nodeType": "VariableDeclaration",
                      "scope": 9505,
                      "src": "6987:10:29",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 9479,
                        "name": "uint256",
                        "nodeType": "ElementaryTypeName",
                        "src": "6987:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 9484,
                  "initialValue": {
                    "argumentTypes": null,
                    "arguments": [],
                    "expression": {
                      "argumentTypes": [],
                      "expression": {
                        "argumentTypes": null,
                        "id": 9481,
                        "name": "cDai",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9206,
                        "src": "7000:4:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_contract$_cERC20_$9160",
                          "typeString": "contract cERC20"
                        }
                      },
                      "id": 9482,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "exchangeRateStored",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 9143,
                      "src": "7000:23:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_external_view$__$returns$_t_uint256_$",
                        "typeString": "function () view external returns (uint256)"
                      }
                    },
                    "id": 9483,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "7000:25:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "6987:38:29"
                },
                {
                  "assignments": [
                    9486
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 9486,
                      "name": "daiBalance",
                      "nodeType": "VariableDeclaration",
                      "scope": 9505,
                      "src": "7123:18:29",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 9485,
                        "name": "uint256",
                        "nodeType": "ElementaryTypeName",
                        "src": "7123:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 9502,
                  "initialValue": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "hexValue": "3130",
                        "id": 9500,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "number",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "7198:2:29",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_rational_10_by_1",
                          "typeString": "int_const 10"
                        },
                        "value": "10"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_rational_10_by_1",
                          "typeString": "int_const 10"
                        }
                      ],
                      "expression": {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "arguments": [
                              {
                                "argumentTypes": null,
                                "hexValue": "31653130",
                                "id": 9495,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": true,
                                "kind": "number",
                                "lValueRequested": false,
                                "nodeType": "Literal",
                                "src": "7183:4:29",
                                "subdenomination": null,
                                "typeDescriptions": {
                                  "typeIdentifier": "t_rational_10000000000_by_1",
                                  "typeString": "int_const 10000000000"
                                },
                                "value": "1e10"
                              }
                            ],
                            "expression": {
                              "argumentTypes": [
                                {
                                  "typeIdentifier": "t_rational_10000000000_by_1",
                                  "typeString": "int_const 10000000000"
                                }
                              ],
                              "expression": {
                                "argumentTypes": null,
                                "arguments": [
                                  {
                                    "argumentTypes": null,
                                    "arguments": [
                                      {
                                        "argumentTypes": null,
                                        "id": 9491,
                                        "name": "this",
                                        "nodeType": "Identifier",
                                        "overloadedDeclarations": [],
                                        "referencedDeclaration": 22327,
                                        "src": "7172:4:29",
                                        "typeDescriptions": {
                                          "typeIdentifier": "t_contract$_SimpleDAIStaking_$9740",
                                          "typeString": "contract SimpleDAIStaking"
                                        }
                                      }
                                    ],
                                    "expression": {
                                      "argumentTypes": [
                                        {
                                          "typeIdentifier": "t_contract$_SimpleDAIStaking_$9740",
                                          "typeString": "contract SimpleDAIStaking"
                                        }
                                      ],
                                      "id": 9490,
                                      "isConstant": false,
                                      "isLValue": false,
                                      "isPure": true,
                                      "lValueRequested": false,
                                      "nodeType": "ElementaryTypeNameExpression",
                                      "src": "7164:7:29",
                                      "typeDescriptions": {
                                        "typeIdentifier": "t_type$_t_address_$",
                                        "typeString": "type(address)"
                                      },
                                      "typeName": "address"
                                    },
                                    "id": 9492,
                                    "isConstant": false,
                                    "isLValue": false,
                                    "isPure": false,
                                    "kind": "typeConversion",
                                    "lValueRequested": false,
                                    "names": [],
                                    "nodeType": "FunctionCall",
                                    "src": "7164:13:29",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_address",
                                      "typeString": "address"
                                    }
                                  }
                                ],
                                "expression": {
                                  "argumentTypes": [
                                    {
                                      "typeIdentifier": "t_address",
                                      "typeString": "address"
                                    }
                                  ],
                                  "expression": {
                                    "argumentTypes": null,
                                    "id": 9488,
                                    "name": "cDai",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 9206,
                                    "src": "7149:4:29",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_contract$_cERC20_$9160",
                                      "typeString": "contract cERC20"
                                    }
                                  },
                                  "id": 9489,
                                  "isConstant": false,
                                  "isLValue": false,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "memberName": "balanceOf",
                                  "nodeType": "MemberAccess",
                                  "referencedDeclaration": 9150,
                                  "src": "7149:14:29",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$",
                                    "typeString": "function (address) view external returns (uint256)"
                                  }
                                },
                                "id": 9493,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": false,
                                "kind": "functionCall",
                                "lValueRequested": false,
                                "names": [],
                                "nodeType": "FunctionCall",
                                "src": "7149:29:29",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_uint256",
                                  "typeString": "uint256"
                                }
                              },
                              "id": 9494,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "lValueRequested": false,
                              "memberName": "mul",
                              "nodeType": "MemberAccess",
                              "referencedDeclaration": 21215,
                              "src": "7149:33:29",
                              "typeDescriptions": {
                                "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
                                "typeString": "function (uint256,uint256) pure returns (uint256)"
                              }
                            },
                            "id": 9496,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": false,
                            "kind": "functionCall",
                            "lValueRequested": false,
                            "names": [],
                            "nodeType": "FunctionCall",
                            "src": "7149:39:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          },
                          {
                            "argumentTypes": null,
                            "id": 9497,
                            "name": "er",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 9480,
                            "src": "7190:2:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            },
                            {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          ],
                          "id": 9487,
                          "name": "rmul",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 199,
                          "src": "7144:4:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$",
                            "typeString": "function (uint256,uint256) pure returns (uint256)"
                          }
                        },
                        "id": 9498,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "functionCall",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "7144:49:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "id": 9499,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "div",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 21239,
                      "src": "7144:53:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
                        "typeString": "function (uint256,uint256) pure returns (uint256)"
                      }
                    },
                    "id": 9501,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "7144:57:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "7123:78:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 9503,
                    "name": "daiBalance",
                    "nodeType": "Identifier",
                    "overloadedDeclarations": [],
                    "referencedDeclaration": 9486,
                    "src": "7218:10:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "functionReturnParameters": 9478,
                  "id": 9504,
                  "nodeType": "Return",
                  "src": "7211:17:29"
                }
              ]
            },
            "documentation": "@dev Calculates the worth of the staked cDAI tokens in DAI.\n@return (uint256) The worth in DAI",
            "id": 9506,
            "implemented": true,
            "kind": "function",
            "modifiers": [],
            "name": "currentDAIWorth",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9475,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "6944:2:29"
            },
            "returnParameters": {
              "id": 9478,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9477,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 9506,
                  "src": "6968:7:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9476,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "6968:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "6967:9:29"
            },
            "scope": 9740,
            "src": "6920:315:29",
            "stateMutability": "view",
            "superFunction": null,
            "visibility": "public"
          },
          {
            "body": {
              "id": 9582,
              "nodeType": "Block",
              "src": "7615:870:29",
              "statements": [
                {
                  "assignments": [
                    9516
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 9516,
                      "name": "er",
                      "nodeType": "VariableDeclaration",
                      "scope": 9582,
                      "src": "7625:10:29",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 9515,
                        "name": "uint256",
                        "nodeType": "ElementaryTypeName",
                        "src": "7625:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 9520,
                  "initialValue": {
                    "argumentTypes": null,
                    "arguments": [],
                    "expression": {
                      "argumentTypes": [],
                      "expression": {
                        "argumentTypes": null,
                        "id": 9517,
                        "name": "cDai",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9206,
                        "src": "7638:4:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_contract$_cERC20_$9160",
                          "typeString": "contract cERC20"
                        }
                      },
                      "id": 9518,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "exchangeRateStored",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 9143,
                      "src": "7638:23:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_external_view$__$returns$_t_uint256_$",
                        "typeString": "function () view external returns (uint256)"
                      }
                    },
                    "id": 9519,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "7638:25:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "7625:38:29"
                },
                {
                  "assignments": [
                    9522
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 9522,
                      "name": "daiWorth",
                      "nodeType": "VariableDeclaration",
                      "scope": 9582,
                      "src": "7673:16:29",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 9521,
                        "name": "uint256",
                        "nodeType": "ElementaryTypeName",
                        "src": "7673:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 9525,
                  "initialValue": {
                    "argumentTypes": null,
                    "arguments": [],
                    "expression": {
                      "argumentTypes": [],
                      "id": 9523,
                      "name": "currentDAIWorth",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9506,
                      "src": "7692:15:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_internal_view$__$returns$_t_uint256_$",
                        "typeString": "function () view returns (uint256)"
                      }
                    },
                    "id": 9524,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "7692:17:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "7673:36:29"
                },
                {
                  "condition": {
                    "argumentTypes": null,
                    "commonType": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    },
                    "id": 9528,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftExpression": {
                      "argumentTypes": null,
                      "id": 9526,
                      "name": "daiWorth",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9522,
                      "src": "7723:8:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "BinaryOperation",
                    "operator": "<=",
                    "rightExpression": {
                      "argumentTypes": null,
                      "id": 9527,
                      "name": "totalStaked",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9213,
                      "src": "7735:11:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "7723:23:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "falseBody": null,
                  "id": 9535,
                  "nodeType": "IfStatement",
                  "src": "7719:70:29",
                  "trueBody": {
                    "id": 9534,
                    "nodeType": "Block",
                    "src": "7748:41:29",
                    "statements": [
                      {
                        "expression": {
                          "argumentTypes": null,
                          "components": [
                            {
                              "argumentTypes": null,
                              "hexValue": "30",
                              "id": 9529,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": true,
                              "kind": "number",
                              "lValueRequested": false,
                              "nodeType": "Literal",
                              "src": "7770:1:29",
                              "subdenomination": null,
                              "typeDescriptions": {
                                "typeIdentifier": "t_rational_0_by_1",
                                "typeString": "int_const 0"
                              },
                              "value": "0"
                            },
                            {
                              "argumentTypes": null,
                              "hexValue": "30",
                              "id": 9530,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": true,
                              "kind": "number",
                              "lValueRequested": false,
                              "nodeType": "Literal",
                              "src": "7773:1:29",
                              "subdenomination": null,
                              "typeDescriptions": {
                                "typeIdentifier": "t_rational_0_by_1",
                                "typeString": "int_const 0"
                              },
                              "value": "0"
                            },
                            {
                              "argumentTypes": null,
                              "hexValue": "30",
                              "id": 9531,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": true,
                              "kind": "number",
                              "lValueRequested": false,
                              "nodeType": "Literal",
                              "src": "7776:1:29",
                              "subdenomination": null,
                              "typeDescriptions": {
                                "typeIdentifier": "t_rational_0_by_1",
                                "typeString": "int_const 0"
                              },
                              "value": "0"
                            }
                          ],
                          "id": 9532,
                          "isConstant": false,
                          "isInlineArray": false,
                          "isLValue": false,
                          "isPure": true,
                          "lValueRequested": false,
                          "nodeType": "TupleExpression",
                          "src": "7769:9:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_tuple$_t_rational_0_by_1_$_t_rational_0_by_1_$_t_rational_0_by_1_$",
                            "typeString": "tuple(int_const 0,int_const 0,int_const 0)"
                          }
                        },
                        "functionReturnParameters": 9514,
                        "id": 9533,
                        "nodeType": "Return",
                        "src": "7762:16:29"
                      }
                    ]
                  }
                },
                {
                  "assignments": [
                    9537
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 9537,
                      "name": "daiGains",
                      "nodeType": "VariableDeclaration",
                      "scope": 9582,
                      "src": "7798:16:29",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 9536,
                        "name": "uint256",
                        "nodeType": "ElementaryTypeName",
                        "src": "7798:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 9542,
                  "initialValue": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "id": 9540,
                        "name": "totalStaked",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9213,
                        "src": "7830:11:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      ],
                      "expression": {
                        "argumentTypes": null,
                        "id": 9538,
                        "name": "daiWorth",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9522,
                        "src": "7817:8:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "id": 9539,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "sub",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 21263,
                      "src": "7817:12:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
                        "typeString": "function (uint256,uint256) pure returns (uint256)"
                      }
                    },
                    "id": 9541,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "7817:25:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "7798:44:29"
                },
                {
                  "assignments": [
                    9544
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 9544,
                      "name": "cdaiGains",
                      "nodeType": "VariableDeclaration",
                      "scope": 9582,
                      "src": "7984:17:29",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 9543,
                        "name": "uint256",
                        "nodeType": "ElementaryTypeName",
                        "src": "7984:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 9552,
                  "initialValue": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "hexValue": "31653130",
                            "id": 9548,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": true,
                            "kind": "number",
                            "lValueRequested": false,
                            "nodeType": "Literal",
                            "src": "8022:4:29",
                            "subdenomination": null,
                            "typeDescriptions": {
                              "typeIdentifier": "t_rational_10000000000_by_1",
                              "typeString": "int_const 10000000000"
                            },
                            "value": "1e10"
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_rational_10000000000_by_1",
                              "typeString": "int_const 10000000000"
                            }
                          ],
                          "expression": {
                            "argumentTypes": null,
                            "id": 9546,
                            "name": "daiGains",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 9537,
                            "src": "8009:8:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          },
                          "id": 9547,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "memberName": "mul",
                          "nodeType": "MemberAccess",
                          "referencedDeclaration": 21215,
                          "src": "8009:12:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
                            "typeString": "function (uint256,uint256) pure returns (uint256)"
                          }
                        },
                        "id": 9549,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "functionCall",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "8009:18:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 9550,
                        "name": "er",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9516,
                        "src": "8029:2:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        },
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      ],
                      "id": 9545,
                      "name": "rdiv",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 247,
                      "src": "8004:4:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$",
                        "typeString": "function (uint256,uint256) pure returns (uint256)"
                      }
                    },
                    "id": 9551,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "8004:28:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "7984:48:29"
                },
                {
                  "assignments": [
                    9554
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 9554,
                      "name": "precisionLossCDaiRay",
                      "nodeType": "VariableDeclaration",
                      "scope": 9582,
                      "src": "8159:28:29",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 9553,
                        "name": "uint256",
                        "nodeType": "ElementaryTypeName",
                        "src": "8159:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 9559,
                  "initialValue": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "hexValue": "31653139",
                        "id": 9557,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "number",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "8204:4:29",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_rational_10000000000000000000_by_1",
                          "typeString": "int_const 10000000000000000000"
                        },
                        "value": "1e19"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_rational_10000000000000000000_by_1",
                          "typeString": "int_const 10000000000000000000"
                        }
                      ],
                      "expression": {
                        "argumentTypes": null,
                        "id": 9555,
                        "name": "cdaiGains",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9544,
                        "src": "8190:9:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "id": 9556,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "mod",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 21307,
                      "src": "8190:13:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
                        "typeString": "function (uint256,uint256) pure returns (uint256)"
                      }
                    },
                    "id": 9558,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "8190:19:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "8159:50:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 9565,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 9560,
                      "name": "cdaiGains",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9544,
                      "src": "8255:9:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "hexValue": "31653139",
                          "id": 9563,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "kind": "number",
                          "lValueRequested": false,
                          "nodeType": "Literal",
                          "src": "8281:4:29",
                          "subdenomination": null,
                          "typeDescriptions": {
                            "typeIdentifier": "t_rational_10000000000000000000_by_1",
                            "typeString": "int_const 10000000000000000000"
                          },
                          "value": "1e19"
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_rational_10000000000000000000_by_1",
                            "typeString": "int_const 10000000000000000000"
                          }
                        ],
                        "expression": {
                          "argumentTypes": null,
                          "id": 9561,
                          "name": "cdaiGains",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9544,
                          "src": "8267:9:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "id": 9562,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "div",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 21239,
                        "src": "8267:13:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
                          "typeString": "function (uint256,uint256) pure returns (uint256)"
                        }
                      },
                      "id": 9564,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "functionCall",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "8267:19:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "8255:31:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 9566,
                  "nodeType": "ExpressionStatement",
                  "src": "8255:31:29"
                },
                {
                  "assignments": [
                    9568
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 9568,
                      "name": "precisionLossDai",
                      "nodeType": "VariableDeclaration",
                      "scope": 9582,
                      "src": "8355:24:29",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 9567,
                        "name": "uint256",
                        "nodeType": "ElementaryTypeName",
                        "src": "8355:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 9576,
                  "initialValue": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "hexValue": "31653130",
                        "id": 9574,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "number",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "8417:4:29",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_rational_10000000000_by_1",
                          "typeString": "int_const 10000000000"
                        },
                        "value": "1e10"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_rational_10000000000_by_1",
                          "typeString": "int_const 10000000000"
                        }
                      ],
                      "expression": {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "id": 9570,
                            "name": "precisionLossCDaiRay",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 9554,
                            "src": "8387:20:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          },
                          {
                            "argumentTypes": null,
                            "id": 9571,
                            "name": "er",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 9516,
                            "src": "8409:2:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            },
                            {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          ],
                          "id": 9569,
                          "name": "rmul",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 199,
                          "src": "8382:4:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$",
                            "typeString": "function (uint256,uint256) pure returns (uint256)"
                          }
                        },
                        "id": 9572,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "functionCall",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "8382:30:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "id": 9573,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "div",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 21239,
                      "src": "8382:34:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
                        "typeString": "function (uint256,uint256) pure returns (uint256)"
                      }
                    },
                    "id": 9575,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "8382:40:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "8355:67:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "components": [
                      {
                        "argumentTypes": null,
                        "id": 9577,
                        "name": "cdaiGains",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9544,
                        "src": "8440:9:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 9578,
                        "name": "daiGains",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9537,
                        "src": "8451:8:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 9579,
                        "name": "precisionLossDai",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9568,
                        "src": "8461:16:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      }
                    ],
                    "id": 9580,
                    "isConstant": false,
                    "isInlineArray": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "nodeType": "TupleExpression",
                    "src": "8439:39:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$",
                      "typeString": "tuple(uint256,uint256,uint256)"
                    }
                  },
                  "functionReturnParameters": 9514,
                  "id": 9581,
                  "nodeType": "Return",
                  "src": "8432:46:29"
                }
              ]
            },
            "documentation": "@dev Calculates the current interest that was gained.\n@return (uint256, uint256, uint256) The interest in cDAI, the interest in DAI,\nthe amount which is not covered by precision of DAI",
            "id": 9583,
            "implemented": true,
            "kind": "function",
            "modifiers": [],
            "name": "currentUBIInterest",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9507,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "7490:2:29"
            },
            "returnParameters": {
              "id": 9514,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9509,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 9583,
                  "src": "7551:7:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9508,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "7551:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9511,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 9583,
                  "src": "7572:7:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9510,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "7572:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9513,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 9583,
                  "src": "7593:7:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9512,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "7593:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "7537:73:29"
            },
            "scope": 9740,
            "src": "7463:1022:29",
            "stateMutability": "view",
            "superFunction": null,
            "visibility": "public"
          },
          {
            "body": {
              "id": 9656,
              "nodeType": "Block",
              "src": "9087:716:29",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "commonType": {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        },
                        "id": 9603,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "leftExpression": {
                          "argumentTypes": null,
                          "id": 9599,
                          "name": "_recipient",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9585,
                          "src": "9173:10:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_address",
                            "typeString": "address"
                          }
                        },
                        "nodeType": "BinaryOperation",
                        "operator": "!=",
                        "rightExpression": {
                          "argumentTypes": null,
                          "arguments": [
                            {
                              "argumentTypes": null,
                              "id": 9601,
                              "name": "this",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 22327,
                              "src": "9195:4:29",
                              "typeDescriptions": {
                                "typeIdentifier": "t_contract$_SimpleDAIStaking_$9740",
                                "typeString": "contract SimpleDAIStaking"
                              }
                            }
                          ],
                          "expression": {
                            "argumentTypes": [
                              {
                                "typeIdentifier": "t_contract$_SimpleDAIStaking_$9740",
                                "typeString": "contract SimpleDAIStaking"
                              }
                            ],
                            "id": 9600,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": true,
                            "lValueRequested": false,
                            "nodeType": "ElementaryTypeNameExpression",
                            "src": "9187:7:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_type$_t_address_$",
                              "typeString": "type(address)"
                            },
                            "typeName": "address"
                          },
                          "id": 9602,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "kind": "typeConversion",
                          "lValueRequested": false,
                          "names": [],
                          "nodeType": "FunctionCall",
                          "src": "9187:13:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_address",
                            "typeString": "address"
                          }
                        },
                        "src": "9173:27:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "hexValue": "526563697069656e742063616e6e6f7420626520746865207374616b696e6720636f6e7472616374",
                        "id": 9604,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "9202:42:29",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_b186bec0df383c90e23d5b956c4da2f18dd93ac86eb077c5c0e428a763cbd6fa",
                          "typeString": "literal_string \"Recipient cannot be the staking contract\""
                        },
                        "value": "Recipient cannot be the staking contract"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        {
                          "typeIdentifier": "t_stringliteral_b186bec0df383c90e23d5b956c4da2f18dd93ac86eb077c5c0e428a763cbd6fa",
                          "typeString": "literal_string \"Recipient cannot be the staking contract\""
                        }
                      ],
                      "id": 9598,
                      "name": "require",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [
                        22174,
                        22175
                      ],
                      "referencedDeclaration": 22175,
                      "src": "9165:7:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                        "typeString": "function (bool,string memory) pure"
                      }
                    },
                    "id": 9605,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "9165:80:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 9606,
                  "nodeType": "ExpressionStatement",
                  "src": "9165:80:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "arguments": [],
                        "expression": {
                          "argumentTypes": [],
                          "id": 9608,
                          "name": "canCollect",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9671,
                          "src": "9264:10:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_function_internal_view$__$returns$_t_bool_$",
                            "typeString": "function () view returns (bool)"
                          }
                        },
                        "id": 9609,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "functionCall",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "9264:12:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "hexValue": "4e65656420746f207761697420666f7220746865206e65787420696e74657276616c",
                        "id": 9610,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "9278:36:29",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_b2926b938aae9e3d3391834a8a3f967955ec6bac9d9b401e186c29404478d446",
                          "typeString": "literal_string \"Need to wait for the next interval\""
                        },
                        "value": "Need to wait for the next interval"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        {
                          "typeIdentifier": "t_stringliteral_b2926b938aae9e3d3391834a8a3f967955ec6bac9d9b401e186c29404478d446",
                          "typeString": "literal_string \"Need to wait for the next interval\""
                        }
                      ],
                      "id": 9607,
                      "name": "require",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [
                        22174,
                        22175
                      ],
                      "referencedDeclaration": 22175,
                      "src": "9256:7:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                        "typeString": "function (bool,string memory) pure"
                      }
                    },
                    "id": 9611,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "9256:59:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 9612,
                  "nodeType": "ExpressionStatement",
                  "src": "9256:59:29"
                },
                {
                  "assignments": [
                    9614,
                    9616,
                    9618
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 9614,
                      "name": "cdaiGains",
                      "nodeType": "VariableDeclaration",
                      "scope": 9656,
                      "src": "9340:17:29",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 9613,
                        "name": "uint256",
                        "nodeType": "ElementaryTypeName",
                        "src": "9340:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    },
                    {
                      "constant": false,
                      "id": 9616,
                      "name": "daiGains",
                      "nodeType": "VariableDeclaration",
                      "scope": 9656,
                      "src": "9371:16:29",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 9615,
                        "name": "uint256",
                        "nodeType": "ElementaryTypeName",
                        "src": "9371:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    },
                    {
                      "constant": false,
                      "id": 9618,
                      "name": "precisionLossDai",
                      "nodeType": "VariableDeclaration",
                      "scope": 9656,
                      "src": "9401:24:29",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 9617,
                        "name": "uint256",
                        "nodeType": "ElementaryTypeName",
                        "src": "9401:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 9621,
                  "initialValue": {
                    "argumentTypes": null,
                    "arguments": [],
                    "expression": {
                      "argumentTypes": [],
                      "id": 9619,
                      "name": "currentUBIInterest",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9583,
                      "src": "9438:18:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_internal_view$__$returns$_t_uint256_$_t_uint256_$_t_uint256_$",
                        "typeString": "function () view returns (uint256,uint256,uint256)"
                      }
                    },
                    "id": 9620,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "9438:20:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$",
                      "typeString": "tuple(uint256,uint256,uint256)"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "9326:132:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 9628,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 9622,
                      "name": "lastUBICollection",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9210,
                      "src": "9468:17:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 9626,
                          "name": "blockInterval",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9208,
                          "src": "9505:13:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        ],
                        "expression": {
                          "argumentTypes": null,
                          "expression": {
                            "argumentTypes": null,
                            "id": 9623,
                            "name": "block",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 22161,
                            "src": "9488:5:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_magic_block",
                              "typeString": "block"
                            }
                          },
                          "id": 9624,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "memberName": "number",
                          "nodeType": "MemberAccess",
                          "referencedDeclaration": null,
                          "src": "9488:12:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "id": 9625,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "div",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 21239,
                        "src": "9488:16:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
                          "typeString": "function (uint256,uint256) pure returns (uint256)"
                        }
                      },
                      "id": 9627,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "functionCall",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "9488:31:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "9468:51:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 9629,
                  "nodeType": "ExpressionStatement",
                  "src": "9468:51:29"
                },
                {
                  "condition": {
                    "argumentTypes": null,
                    "commonType": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    },
                    "id": 9632,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftExpression": {
                      "argumentTypes": null,
                      "id": 9630,
                      "name": "cdaiGains",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9614,
                      "src": "9533:9:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "BinaryOperation",
                    "operator": ">",
                    "rightExpression": {
                      "argumentTypes": null,
                      "hexValue": "30",
                      "id": 9631,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": true,
                      "kind": "number",
                      "lValueRequested": false,
                      "nodeType": "Literal",
                      "src": "9545:1:29",
                      "subdenomination": null,
                      "typeDescriptions": {
                        "typeIdentifier": "t_rational_0_by_1",
                        "typeString": "int_const 0"
                      },
                      "value": "0"
                    },
                    "src": "9533:13:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "falseBody": null,
                  "id": 9642,
                  "nodeType": "IfStatement",
                  "src": "9529:103:29",
                  "trueBody": {
                    "expression": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "arguments": [
                            {
                              "argumentTypes": null,
                              "id": 9636,
                              "name": "_recipient",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 9585,
                              "src": "9582:10:29",
                              "typeDescriptions": {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "id": 9637,
                              "name": "cdaiGains",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 9614,
                              "src": "9594:9:29",
                              "typeDescriptions": {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              }
                            }
                          ],
                          "expression": {
                            "argumentTypes": [
                              {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              },
                              {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              }
                            ],
                            "expression": {
                              "argumentTypes": null,
                              "id": 9634,
                              "name": "cDai",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 9206,
                              "src": "9568:4:29",
                              "typeDescriptions": {
                                "typeIdentifier": "t_contract$_cERC20_$9160",
                                "typeString": "contract cERC20"
                              }
                            },
                            "id": 9635,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": false,
                            "lValueRequested": false,
                            "memberName": "transfer",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": 9159,
                            "src": "9568:13:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$",
                              "typeString": "function (address,uint256) external returns (bool)"
                            }
                          },
                          "id": 9638,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "kind": "functionCall",
                          "lValueRequested": false,
                          "names": [],
                          "nodeType": "FunctionCall",
                          "src": "9568:36:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_bool",
                            "typeString": "bool"
                          }
                        },
                        {
                          "argumentTypes": null,
                          "hexValue": "636f6c6c656374207472616e73666572206661696c6564",
                          "id": 9639,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "kind": "string",
                          "lValueRequested": false,
                          "nodeType": "Literal",
                          "src": "9606:25:29",
                          "subdenomination": null,
                          "typeDescriptions": {
                            "typeIdentifier": "t_stringliteral_c955f53632207d8104a997da6e051a24feef1c53c0972ac3af4bdda83f5d190e",
                            "typeString": "literal_string \"collect transfer failed\""
                          },
                          "value": "collect transfer failed"
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_bool",
                            "typeString": "bool"
                          },
                          {
                            "typeIdentifier": "t_stringliteral_c955f53632207d8104a997da6e051a24feef1c53c0972ac3af4bdda83f5d190e",
                            "typeString": "literal_string \"collect transfer failed\""
                          }
                        ],
                        "id": 9633,
                        "name": "require",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [
                          22174,
                          22175
                        ],
                        "referencedDeclaration": 22175,
                        "src": "9560:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                          "typeString": "function (bool,string memory) pure"
                        }
                      },
                      "id": 9640,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "functionCall",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "9560:72:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_tuple$__$",
                        "typeString": "tuple()"
                      }
                    },
                    "id": 9641,
                    "nodeType": "ExpressionStatement",
                    "src": "9560:72:29"
                  }
                },
                {
                  "eventCall": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "id": 9644,
                        "name": "_recipient",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9585,
                        "src": "9665:10:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 9645,
                        "name": "cdaiGains",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9614,
                        "src": "9677:9:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 9646,
                        "name": "daiGains",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9616,
                        "src": "9688:8:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 9647,
                        "name": "precisionLossDai",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9618,
                        "src": "9698:16:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        },
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        },
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        },
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      ],
                      "id": 9643,
                      "name": "InterestCollected",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9202,
                      "src": "9647:17:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$_t_uint256_$returns$__$",
                        "typeString": "function (address,uint256,uint256,uint256)"
                      }
                    },
                    "id": 9648,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "9647:68:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 9649,
                  "nodeType": "EmitStatement",
                  "src": "9642:73:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "components": [
                      {
                        "argumentTypes": null,
                        "id": 9650,
                        "name": "cdaiGains",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9614,
                        "src": "9733:9:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 9651,
                        "name": "daiGains",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9616,
                        "src": "9744:8:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 9652,
                        "name": "precisionLossDai",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9618,
                        "src": "9754:16:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 9653,
                        "name": "avgInterestDonatedRatio",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9216,
                        "src": "9772:23:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint32",
                          "typeString": "uint32"
                        }
                      }
                    ],
                    "id": 9654,
                    "isConstant": false,
                    "isInlineArray": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "nodeType": "TupleExpression",
                    "src": "9732:64:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint32_$",
                      "typeString": "tuple(uint256,uint256,uint256,uint32)"
                    }
                  },
                  "functionReturnParameters": 9597,
                  "id": 9655,
                  "nodeType": "Return",
                  "src": "9725:71:29"
                }
              ]
            },
            "documentation": "@dev Collects gained interest by fundmanager. Can be collected only once\nin an interval which is defined above.\n@param _recipient The recipient of cDAI gains\n@return (uint256, uint256, uint256, uint32) The interest in cDAI, the interest in DAI,\nthe amount which is not covered by precision of DAI, how much of the generated interest is donated",
            "id": 9657,
            "implemented": true,
            "kind": "function",
            "modifiers": [
              {
                "arguments": null,
                "id": 9588,
                "modifierName": {
                  "argumentTypes": null,
                  "id": 9587,
                  "name": "onlyFundManager",
                  "nodeType": "Identifier",
                  "overloadedDeclarations": [],
                  "referencedDeclaration": 9230,
                  "src": "8957:15:29",
                  "typeDescriptions": {
                    "typeIdentifier": "t_modifier$__$",
                    "typeString": "modifier ()"
                  }
                },
                "nodeType": "ModifierInvocation",
                "src": "8957:15:29"
              }
            ],
            "name": "collectUBIInterest",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9586,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9585,
                  "name": "_recipient",
                  "nodeType": "VariableDeclaration",
                  "scope": 9657,
                  "src": "8914:18:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 9584,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "8914:7:29",
                    "stateMutability": "nonpayable",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "8913:20:29"
            },
            "returnParameters": {
              "id": 9597,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9590,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 9657,
                  "src": "9003:7:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9589,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "9003:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9592,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 9657,
                  "src": "9024:7:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9591,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "9024:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9594,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 9657,
                  "src": "9045:7:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9593,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "9045:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9596,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 9657,
                  "src": "9066:6:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint32",
                    "typeString": "uint32"
                  },
                  "typeName": {
                    "id": 9595,
                    "name": "uint32",
                    "nodeType": "ElementaryTypeName",
                    "src": "9066:6:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint32",
                      "typeString": "uint32"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "8989:93:29"
            },
            "scope": 9740,
            "src": "8886:917:29",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "public"
          },
          {
            "body": {
              "id": 9670,
              "nodeType": "Block",
              "src": "10084:75:29",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "commonType": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    },
                    "id": 9668,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftExpression": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 9665,
                          "name": "blockInterval",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9208,
                          "src": "10118:13:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        ],
                        "expression": {
                          "argumentTypes": null,
                          "expression": {
                            "argumentTypes": null,
                            "id": 9662,
                            "name": "block",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 22161,
                            "src": "10101:5:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_magic_block",
                              "typeString": "block"
                            }
                          },
                          "id": 9663,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "memberName": "number",
                          "nodeType": "MemberAccess",
                          "referencedDeclaration": null,
                          "src": "10101:12:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "id": 9664,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "div",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 21239,
                        "src": "10101:16:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
                          "typeString": "function (uint256,uint256) pure returns (uint256)"
                        }
                      },
                      "id": 9666,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "functionCall",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "10101:31:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "BinaryOperation",
                    "operator": ">",
                    "rightExpression": {
                      "argumentTypes": null,
                      "id": 9667,
                      "name": "lastUBICollection",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9210,
                      "src": "10135:17:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "10101:51:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "functionReturnParameters": 9661,
                  "id": 9669,
                  "nodeType": "Return",
                  "src": "10094:58:29"
                }
              ]
            },
            "documentation": "@dev Checks if enough blocks have passed so it would be possible to\nexecute `collectUBIInterest` according to the length of `blockInterval`\n@return (bool) True if enough blocks have passed",
            "id": 9671,
            "implemented": true,
            "kind": "function",
            "modifiers": [],
            "name": "canCollect",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9658,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "10054:2:29"
            },
            "returnParameters": {
              "id": 9661,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9660,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 9671,
                  "src": "10078:4:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_bool",
                    "typeString": "bool"
                  },
                  "typeName": {
                    "id": 9659,
                    "name": "bool",
                    "nodeType": "ElementaryTypeName",
                    "src": "10078:4:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "10077:6:29"
            },
            "scope": 9740,
            "src": "10035:124:29",
            "stateMutability": "view",
            "superFunction": null,
            "visibility": "public"
          },
          {
            "body": {
              "id": 9679,
              "nodeType": "Block",
              "src": "10350:28:29",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [],
                    "expression": {
                      "argumentTypes": [],
                      "id": 9676,
                      "name": "addRights",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 1203,
                      "src": "10360:9:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_internal_nonpayable$__$returns$__$",
                        "typeString": "function ()"
                      }
                    },
                    "id": 9677,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "10360:11:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 9678,
                  "nodeType": "ExpressionStatement",
                  "src": "10360:11:29"
                }
              ]
            },
            "documentation": "@dev Start function. Adds this contract to identity as a feeless scheme.\nCan only be called if scheme is registered",
            "id": 9680,
            "implemented": true,
            "kind": "function",
            "modifiers": [
              {
                "arguments": null,
                "id": 9674,
                "modifierName": {
                  "argumentTypes": null,
                  "id": 9673,
                  "name": "onlyRegistered",
                  "nodeType": "Identifier",
                  "overloadedDeclarations": [],
                  "referencedDeclaration": 1335,
                  "src": "10335:14:29",
                  "typeDescriptions": {
                    "typeIdentifier": "t_modifier$__$",
                    "typeString": "modifier ()"
                  }
                },
                "nodeType": "ModifierInvocation",
                "src": "10335:14:29"
              }
            ],
            "name": "start",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9672,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "10325:2:29"
            },
            "returnParameters": {
              "id": 9675,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "10350:0:29"
            },
            "scope": 9740,
            "src": "10311:67:29",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "public"
          },
          {
            "body": {
              "id": 9691,
              "nodeType": "Block",
              "src": "10643:48:29",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [],
                    "expression": {
                      "argumentTypes": [],
                      "id": 9685,
                      "name": "pause",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 21093,
                      "src": "10653:5:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_internal_nonpayable$__$returns$__$",
                        "typeString": "function ()"
                      }
                    },
                    "id": 9686,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "10653:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 9687,
                  "nodeType": "ExpressionStatement",
                  "src": "10653:7:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [],
                    "expression": {
                      "argumentTypes": [],
                      "id": 9688,
                      "name": "removeRights",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 1226,
                      "src": "10670:12:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_internal_nonpayable$__$returns$__$",
                        "typeString": "function ()"
                      }
                    },
                    "id": 9689,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "10670:14:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 9690,
                  "nodeType": "ExpressionStatement",
                  "src": "10670:14:29"
                }
              ]
            },
            "documentation": "@dev making the contract inactive\nNOTICE: this could theoretically result in future interest earned in cdai to remain locked\nbut we dont expect any other stakers but us in SimpleDAIStaking",
            "id": 9692,
            "implemented": true,
            "kind": "function",
            "modifiers": [
              {
                "arguments": null,
                "id": 9683,
                "modifierName": {
                  "argumentTypes": null,
                  "id": 9682,
                  "name": "onlyAvatar",
                  "nodeType": "Identifier",
                  "overloadedDeclarations": [],
                  "referencedDeclaration": 1325,
                  "src": "10632:10:29",
                  "typeDescriptions": {
                    "typeIdentifier": "t_modifier$__$",
                    "typeString": "modifier ()"
                  }
                },
                "nodeType": "ModifierInvocation",
                "src": "10632:10:29"
              }
            ],
            "name": "end",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9681,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "10622:2:29"
            },
            "returnParameters": {
              "id": 9684,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "10643:0:29"
            },
            "scope": 9740,
            "src": "10610:81:29",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "public"
          },
          {
            "body": {
              "id": 9738,
              "nodeType": "Block",
              "src": "10883:457:29",
              "statements": [
                {
                  "assignments": [
                    9700
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 9700,
                      "name": "toWithdraw",
                      "nodeType": "VariableDeclaration",
                      "scope": 9738,
                      "src": "10893:18:29",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 9699,
                        "name": "uint256",
                        "nodeType": "ElementaryTypeName",
                        "src": "10893:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 9707,
                  "initialValue": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "id": 9704,
                            "name": "this",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 22327,
                            "src": "10939:4:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_contract$_SimpleDAIStaking_$9740",
                              "typeString": "contract SimpleDAIStaking"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_contract$_SimpleDAIStaking_$9740",
                              "typeString": "contract SimpleDAIStaking"
                            }
                          ],
                          "id": 9703,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "lValueRequested": false,
                          "nodeType": "ElementaryTypeNameExpression",
                          "src": "10931:7:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_address_$",
                            "typeString": "type(address)"
                          },
                          "typeName": "address"
                        },
                        "id": 9705,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "typeConversion",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "10931:13:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      ],
                      "expression": {
                        "argumentTypes": null,
                        "id": 9701,
                        "name": "_token",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9694,
                        "src": "10914:6:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_contract$_ERC20_$21849",
                          "typeString": "contract ERC20"
                        }
                      },
                      "id": 9702,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "balanceOf",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 21458,
                      "src": "10914:16:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$",
                        "typeString": "function (address) view external returns (uint256)"
                      }
                    },
                    "id": 9706,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "10914:31:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "10893:52:29"
                },
                {
                  "condition": {
                    "argumentTypes": null,
                    "commonType": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    },
                    "id": 9714,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftExpression": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 9709,
                          "name": "_token",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9694,
                          "src": "11053:6:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_contract$_ERC20_$21849",
                            "typeString": "contract ERC20"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_contract$_ERC20_$21849",
                            "typeString": "contract ERC20"
                          }
                        ],
                        "id": 9708,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "lValueRequested": false,
                        "nodeType": "ElementaryTypeNameExpression",
                        "src": "11045:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_type$_t_address_$",
                          "typeString": "type(address)"
                        },
                        "typeName": "address"
                      },
                      "id": 9710,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "typeConversion",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "11045:15:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "nodeType": "BinaryOperation",
                    "operator": "==",
                    "rightExpression": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 9712,
                          "name": "cDai",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9206,
                          "src": "11072:4:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_contract$_cERC20_$9160",
                            "typeString": "contract cERC20"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_contract$_cERC20_$9160",
                            "typeString": "contract cERC20"
                          }
                        ],
                        "id": 9711,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "lValueRequested": false,
                        "nodeType": "ElementaryTypeNameExpression",
                        "src": "11064:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_type$_t_address_$",
                          "typeString": "type(address)"
                        },
                        "typeName": "address"
                      },
                      "id": 9713,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "typeConversion",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "11064:13:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "src": "11045:32:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "falseBody": null,
                  "id": 9726,
                  "nodeType": "IfStatement",
                  "src": "11041:203:29",
                  "trueBody": {
                    "id": 9725,
                    "nodeType": "Block",
                    "src": "11079:165:29",
                    "statements": [
                      {
                        "expression": {
                          "argumentTypes": null,
                          "arguments": [
                            {
                              "argumentTypes": null,
                              "commonType": {
                                "typeIdentifier": "t_bool",
                                "typeString": "bool"
                              },
                              "id": 9721,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "lValueRequested": false,
                              "leftExpression": {
                                "argumentTypes": null,
                                "commonType": {
                                  "typeIdentifier": "t_uint256",
                                  "typeString": "uint256"
                                },
                                "id": 9718,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": false,
                                "lValueRequested": false,
                                "leftExpression": {
                                  "argumentTypes": null,
                                  "id": 9716,
                                  "name": "totalStaked",
                                  "nodeType": "Identifier",
                                  "overloadedDeclarations": [],
                                  "referencedDeclaration": 9213,
                                  "src": "11118:11:29",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                },
                                "nodeType": "BinaryOperation",
                                "operator": "==",
                                "rightExpression": {
                                  "argumentTypes": null,
                                  "hexValue": "30",
                                  "id": 9717,
                                  "isConstant": false,
                                  "isLValue": false,
                                  "isPure": true,
                                  "kind": "number",
                                  "lValueRequested": false,
                                  "nodeType": "Literal",
                                  "src": "11133:1:29",
                                  "subdenomination": null,
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_rational_0_by_1",
                                    "typeString": "int_const 0"
                                  },
                                  "value": "0"
                                },
                                "src": "11118:16:29",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_bool",
                                  "typeString": "bool"
                                }
                              },
                              "nodeType": "BinaryOperation",
                              "operator": "&&",
                              "rightExpression": {
                                "argumentTypes": null,
                                "arguments": [],
                                "expression": {
                                  "argumentTypes": [],
                                  "id": 9719,
                                  "name": "paused",
                                  "nodeType": "Identifier",
                                  "overloadedDeclarations": [],
                                  "referencedDeclaration": 21059,
                                  "src": "11138:6:29",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_function_internal_view$__$returns$_t_bool_$",
                                    "typeString": "function () view returns (bool)"
                                  }
                                },
                                "id": 9720,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": false,
                                "kind": "functionCall",
                                "lValueRequested": false,
                                "names": [],
                                "nodeType": "FunctionCall",
                                "src": "11138:8:29",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_bool",
                                  "typeString": "bool"
                                }
                              },
                              "src": "11118:28:29",
                              "typeDescriptions": {
                                "typeIdentifier": "t_bool",
                                "typeString": "bool"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "hexValue": "63616e207265636f7665722063446169206f6e6c79207768656e207374616b65732068617665206265656e2077697468647261776e",
                              "id": 9722,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": true,
                              "kind": "string",
                              "lValueRequested": false,
                              "nodeType": "Literal",
                              "src": "11164:55:29",
                              "subdenomination": null,
                              "typeDescriptions": {
                                "typeIdentifier": "t_stringliteral_79607305dd51ed20c601fc68ead0738527c2757f2ece05378363c3502b2aaa0c",
                                "typeString": "literal_string \"can recover cDai only when stakes have been withdrawn\""
                              },
                              "value": "can recover cDai only when stakes have been withdrawn"
                            }
                          ],
                          "expression": {
                            "argumentTypes": [
                              {
                                "typeIdentifier": "t_bool",
                                "typeString": "bool"
                              },
                              {
                                "typeIdentifier": "t_stringliteral_79607305dd51ed20c601fc68ead0738527c2757f2ece05378363c3502b2aaa0c",
                                "typeString": "literal_string \"can recover cDai only when stakes have been withdrawn\""
                              }
                            ],
                            "id": 9715,
                            "name": "require",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [
                              22174,
                              22175
                            ],
                            "referencedDeclaration": 22175,
                            "src": "11093:7:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                              "typeString": "function (bool,string memory) pure"
                            }
                          },
                          "id": 9723,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "kind": "functionCall",
                          "lValueRequested": false,
                          "names": [],
                          "nodeType": "FunctionCall",
                          "src": "11093:140:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_tuple$__$",
                            "typeString": "tuple()"
                          }
                        },
                        "id": 9724,
                        "nodeType": "ExpressionStatement",
                        "src": "11093:140:29"
                      }
                    ]
                  }
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "arguments": [
                              {
                                "argumentTypes": null,
                                "id": 9731,
                                "name": "avatar",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 1281,
                                "src": "11285:6:29",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_contract$_Avatar_$12705",
                                  "typeString": "contract Avatar"
                                }
                              }
                            ],
                            "expression": {
                              "argumentTypes": [
                                {
                                  "typeIdentifier": "t_contract$_Avatar_$12705",
                                  "typeString": "contract Avatar"
                                }
                              ],
                              "id": 9730,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": true,
                              "lValueRequested": false,
                              "nodeType": "ElementaryTypeNameExpression",
                              "src": "11277:7:29",
                              "typeDescriptions": {
                                "typeIdentifier": "t_type$_t_address_$",
                                "typeString": "type(address)"
                              },
                              "typeName": "address"
                            },
                            "id": 9732,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": false,
                            "kind": "typeConversion",
                            "lValueRequested": false,
                            "names": [],
                            "nodeType": "FunctionCall",
                            "src": "11277:15:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_address_payable",
                              "typeString": "address payable"
                            }
                          },
                          {
                            "argumentTypes": null,
                            "id": 9733,
                            "name": "toWithdraw",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 9700,
                            "src": "11294:10:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_address_payable",
                              "typeString": "address payable"
                            },
                            {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          ],
                          "expression": {
                            "argumentTypes": null,
                            "id": 9728,
                            "name": "_token",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 9694,
                            "src": "11261:6:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_contract$_ERC20_$21849",
                              "typeString": "contract ERC20"
                            }
                          },
                          "id": 9729,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "memberName": "transfer",
                          "nodeType": "MemberAccess",
                          "referencedDeclaration": 21493,
                          "src": "11261:15:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$",
                            "typeString": "function (address,uint256) external returns (bool)"
                          }
                        },
                        "id": 9734,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "functionCall",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "11261:44:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "hexValue": "7265636f766572207472616e73666572206661696c6564",
                        "id": 9735,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "11307:25:29",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_41a03013a5674cc54e9badb52c47e3c4670bc54fa0765e5276b5118633f8aeb3",
                          "typeString": "literal_string \"recover transfer failed\""
                        },
                        "value": "recover transfer failed"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        {
                          "typeIdentifier": "t_stringliteral_41a03013a5674cc54e9badb52c47e3c4670bc54fa0765e5276b5118633f8aeb3",
                          "typeString": "literal_string \"recover transfer failed\""
                        }
                      ],
                      "id": 9727,
                      "name": "require",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [
                        22174,
                        22175
                      ],
                      "referencedDeclaration": 22175,
                      "src": "11253:7:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                        "typeString": "function (bool,string memory) pure"
                      }
                    },
                    "id": 9736,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "11253:80:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 9737,
                  "nodeType": "ExpressionStatement",
                  "src": "11253:80:29"
                }
              ]
            },
            "documentation": "@dev method to recover any stuck erc20 tokens (ie  compound COMP)\n@param _token the ERC20 token to recover",
            "id": 9739,
            "implemented": true,
            "kind": "function",
            "modifiers": [
              {
                "arguments": null,
                "id": 9697,
                "modifierName": {
                  "argumentTypes": null,
                  "id": 9696,
                  "name": "onlyAvatar",
                  "nodeType": "Identifier",
                  "overloadedDeclarations": [],
                  "referencedDeclaration": 1325,
                  "src": "10872:10:29",
                  "typeDescriptions": {
                    "typeIdentifier": "t_modifier$__$",
                    "typeString": "modifier ()"
                  }
                },
                "nodeType": "ModifierInvocation",
                "src": "10872:10:29"
              }
            ],
            "name": "recover",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9695,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9694,
                  "name": "_token",
                  "nodeType": "VariableDeclaration",
                  "scope": 9739,
                  "src": "10851:12:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_contract$_ERC20_$21849",
                    "typeString": "contract ERC20"
                  },
                  "typeName": {
                    "contractScope": null,
                    "id": 9693,
                    "name": "ERC20",
                    "nodeType": "UserDefinedTypeName",
                    "referencedDeclaration": 21849,
                    "src": "10851:5:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_contract$_ERC20_$21849",
                      "typeString": "contract ERC20"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "10850:14:29"
            },
            "returnParameters": {
              "id": 9698,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "10883:0:29"
            },
            "scope": 9740,
            "src": "10834:506:29",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "public"
          }
        ],
        "scope": 9741,
        "src": "1073:10269:29"
      }
    ],
    "src": "0:11343:29"
  },
  "legacyAST": {
    "absolutePath": "/Users/hadar/workspace/GoodDollar/GoodBootstrap/packages/contracts/stakingModel/contracts/SimpleDAIStaking.sol",
    "exportedSymbols": {
      "SimpleDAIStaking": [
        9740
      ],
      "cERC20": [
        9160
      ]
    },
    "id": 9741,
    "nodeType": "SourceUnit",
    "nodes": [
      {
        "id": 9112,
        "literals": [
          "solidity",
          ">",
          "0.5",
          ".4"
        ],
        "nodeType": "PragmaDirective",
        "src": "0:23:29"
      },
      {
        "absolutePath": "openzeppelin-solidity/contracts/math/SafeMath.sol",
        "file": "openzeppelin-solidity/contracts/math/SafeMath.sol",
        "id": 9113,
        "nodeType": "ImportDirective",
        "scope": 9741,
        "sourceUnit": 21309,
        "src": "25:59:29",
        "symbolAliases": [],
        "unitAlias": ""
      },
      {
        "absolutePath": "openzeppelin-solidity/contracts/lifecycle/Pausable.sol",
        "file": "openzeppelin-solidity/contracts/lifecycle/Pausable.sol",
        "id": 9114,
        "nodeType": "ImportDirective",
        "scope": 9741,
        "sourceUnit": 21112,
        "src": "85:64:29",
        "symbolAliases": [],
        "unitAlias": ""
      },
      {
        "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/ERC20.sol",
        "file": "openzeppelin-solidity/contracts/token/ERC20/ERC20.sol",
        "id": 9115,
        "nodeType": "ImportDirective",
        "scope": 9741,
        "sourceUnit": 21850,
        "src": "150:63:29",
        "symbolAliases": [],
        "unitAlias": ""
      },
      {
        "absolutePath": "@daostack/arc/contracts/controller/Avatar.sol",
        "file": "@daostack/arc/contracts/controller/Avatar.sol",
        "id": 9116,
        "nodeType": "ImportDirective",
        "scope": 9741,
        "sourceUnit": 12706,
        "src": "214:55:29",
        "symbolAliases": [],
        "unitAlias": ""
      },
      {
        "absolutePath": "/Users/hadar/workspace/GoodDollar/GoodBootstrap/packages/contracts/contracts/dao/schemes/FeelessScheme.sol",
        "file": "../../contracts/dao/schemes/FeelessScheme.sol",
        "id": 9117,
        "nodeType": "ImportDirective",
        "scope": 9741,
        "sourceUnit": 1228,
        "src": "270:55:29",
        "symbolAliases": [],
        "unitAlias": ""
      },
      {
        "absolutePath": "/Users/hadar/workspace/GoodDollar/GoodBootstrap/packages/contracts/contracts/identity/Identity.sol",
        "file": "../../contracts/identity/Identity.sol",
        "id": 9118,
        "nodeType": "ImportDirective",
        "scope": 9741,
        "sourceUnit": 2381,
        "src": "326:47:29",
        "symbolAliases": [],
        "unitAlias": ""
      },
      {
        "absolutePath": "/Users/hadar/workspace/GoodDollar/GoodBootstrap/packages/contracts/contracts/DSMath.sol",
        "file": "../../contracts/DSMath.sol",
        "id": 9119,
        "nodeType": "ImportDirective",
        "scope": 9741,
        "sourceUnit": 304,
        "src": "374:36:29",
        "symbolAliases": [],
        "unitAlias": ""
      },
      {
        "baseContracts": [],
        "contractDependencies": [],
        "contractKind": "interface",
        "documentation": null,
        "fullyImplemented": false,
        "id": 9160,
        "linearizedBaseContracts": [
          9160
        ],
        "name": "cERC20",
        "nodeType": "ContractDefinition",
        "nodes": [
          {
            "body": null,
            "documentation": null,
            "id": 9126,
            "implemented": false,
            "kind": "function",
            "modifiers": [],
            "name": "mint",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9122,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9121,
                  "name": "mintAmount",
                  "nodeType": "VariableDeclaration",
                  "scope": 9126,
                  "src": "449:18:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9120,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "449:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "448:20:29"
            },
            "returnParameters": {
              "id": 9125,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9124,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 9126,
                  "src": "487:7:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9123,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "487:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "486:9:29"
            },
            "scope": 9160,
            "src": "435:61:29",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "external"
          },
          {
            "body": null,
            "documentation": null,
            "id": 9133,
            "implemented": false,
            "kind": "function",
            "modifiers": [],
            "name": "redeemUnderlying",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9129,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9128,
                  "name": "mintAmount",
                  "nodeType": "VariableDeclaration",
                  "scope": 9133,
                  "src": "528:18:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9127,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "528:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "527:20:29"
            },
            "returnParameters": {
              "id": 9132,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9131,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 9133,
                  "src": "566:7:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9130,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "566:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "565:9:29"
            },
            "scope": 9160,
            "src": "502:73:29",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "external"
          },
          {
            "body": null,
            "documentation": null,
            "id": 9138,
            "implemented": false,
            "kind": "function",
            "modifiers": [],
            "name": "exchangeRateCurrent",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9134,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "609:2:29"
            },
            "returnParameters": {
              "id": 9137,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9136,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 9138,
                  "src": "630:7:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9135,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "630:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "629:9:29"
            },
            "scope": 9160,
            "src": "581:58:29",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "external"
          },
          {
            "body": null,
            "documentation": null,
            "id": 9143,
            "implemented": false,
            "kind": "function",
            "modifiers": [],
            "name": "exchangeRateStored",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9139,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "672:2:29"
            },
            "returnParameters": {
              "id": 9142,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9141,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 9143,
                  "src": "698:7:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9140,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "698:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "697:9:29"
            },
            "scope": 9160,
            "src": "645:62:29",
            "stateMutability": "view",
            "superFunction": null,
            "visibility": "external"
          },
          {
            "body": null,
            "documentation": null,
            "id": 9150,
            "implemented": false,
            "kind": "function",
            "modifiers": [],
            "name": "balanceOf",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9146,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9145,
                  "name": "addr",
                  "nodeType": "VariableDeclaration",
                  "scope": 9150,
                  "src": "732:12:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 9144,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "732:7:29",
                    "stateMutability": "nonpayable",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "731:14:29"
            },
            "returnParameters": {
              "id": 9149,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9148,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 9150,
                  "src": "769:7:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9147,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "769:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "768:9:29"
            },
            "scope": 9160,
            "src": "713:65:29",
            "stateMutability": "view",
            "superFunction": null,
            "visibility": "external"
          },
          {
            "body": null,
            "documentation": null,
            "id": 9159,
            "implemented": false,
            "kind": "function",
            "modifiers": [],
            "name": "transfer",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9155,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9152,
                  "name": "to",
                  "nodeType": "VariableDeclaration",
                  "scope": 9159,
                  "src": "802:10:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 9151,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "802:7:29",
                    "stateMutability": "nonpayable",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9154,
                  "name": "amount",
                  "nodeType": "VariableDeclaration",
                  "scope": 9159,
                  "src": "814:14:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9153,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "814:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "801:28:29"
            },
            "returnParameters": {
              "id": 9158,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9157,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 9159,
                  "src": "848:4:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_bool",
                    "typeString": "bool"
                  },
                  "typeName": {
                    "id": 9156,
                    "name": "bool",
                    "nodeType": "ElementaryTypeName",
                    "src": "848:4:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "847:6:29"
            },
            "scope": 9160,
            "src": "784:70:29",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "external"
          }
        ],
        "scope": 9741,
        "src": "412:444:29"
      },
      {
        "baseContracts": [
          {
            "arguments": null,
            "baseName": {
              "contractScope": null,
              "id": 9161,
              "name": "DSMath",
              "nodeType": "UserDefinedTypeName",
              "referencedDeclaration": 303,
              "src": "1102:6:29",
              "typeDescriptions": {
                "typeIdentifier": "t_contract$_DSMath_$303",
                "typeString": "contract DSMath"
              }
            },
            "id": 9162,
            "nodeType": "InheritanceSpecifier",
            "src": "1102:6:29"
          },
          {
            "arguments": null,
            "baseName": {
              "contractScope": null,
              "id": 9163,
              "name": "Pausable",
              "nodeType": "UserDefinedTypeName",
              "referencedDeclaration": 21111,
              "src": "1110:8:29",
              "typeDescriptions": {
                "typeIdentifier": "t_contract$_Pausable_$21111",
                "typeString": "contract Pausable"
              }
            },
            "id": 9164,
            "nodeType": "InheritanceSpecifier",
            "src": "1110:8:29"
          },
          {
            "arguments": null,
            "baseName": {
              "contractScope": null,
              "id": 9165,
              "name": "FeelessScheme",
              "nodeType": "UserDefinedTypeName",
              "referencedDeclaration": 1227,
              "src": "1120:13:29",
              "typeDescriptions": {
                "typeIdentifier": "t_contract$_FeelessScheme_$1227",
                "typeString": "contract FeelessScheme"
              }
            },
            "id": 9166,
            "nodeType": "InheritanceSpecifier",
            "src": "1120:13:29"
          }
        ],
        "contractDependencies": [
          303,
          1227,
          1423,
          2667,
          20947,
          21111,
          21417
        ],
        "contractKind": "contract",
        "documentation": "@title Staking contract that donates earned interest to the DAO\nallowing stakers to deposit DAI or withdraw their stake in DAI.\nThe contract buys cDAI and can transfer the daily interest to the DAO",
        "fullyImplemented": true,
        "id": 9740,
        "linearizedBaseContracts": [
          9740,
          1227,
          2667,
          1423,
          21417,
          21111,
          20947,
          303
        ],
        "name": "SimpleDAIStaking",
        "nodeType": "ContractDefinition",
        "nodes": [
          {
            "id": 9169,
            "libraryName": {
              "contractScope": null,
              "id": 9167,
              "name": "SafeMath",
              "nodeType": "UserDefinedTypeName",
              "referencedDeclaration": 21308,
              "src": "1146:8:29",
              "typeDescriptions": {
                "typeIdentifier": "t_contract$_SafeMath_$21308",
                "typeString": "library SafeMath"
              }
            },
            "nodeType": "UsingForDirective",
            "src": "1140:27:29",
            "typeName": {
              "id": 9168,
              "name": "uint256",
              "nodeType": "ElementaryTypeName",
              "src": "1159:7:29",
              "typeDescriptions": {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              }
            }
          },
          {
            "canonicalName": "SimpleDAIStaking.Staker",
            "id": 9174,
            "members": [
              {
                "constant": false,
                "id": 9171,
                "name": "stakedDAI",
                "nodeType": "VariableDeclaration",
                "scope": 9174,
                "src": "1269:17:29",
                "stateVariable": false,
                "storageLocation": "default",
                "typeDescriptions": {
                  "typeIdentifier": "t_uint256",
                  "typeString": "uint256"
                },
                "typeName": {
                  "id": 9170,
                  "name": "uint256",
                  "nodeType": "ElementaryTypeName",
                  "src": "1269:7:29",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  }
                },
                "value": null,
                "visibility": "internal"
              },
              {
                "constant": false,
                "id": 9173,
                "name": "lastStake",
                "nodeType": "VariableDeclaration",
                "scope": 9174,
                "src": "1377:17:29",
                "stateVariable": false,
                "storageLocation": "default",
                "typeDescriptions": {
                  "typeIdentifier": "t_uint256",
                  "typeString": "uint256"
                },
                "typeName": {
                  "id": 9172,
                  "name": "uint256",
                  "nodeType": "ElementaryTypeName",
                  "src": "1377:7:29",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  }
                },
                "value": null,
                "visibility": "internal"
              }
            ],
            "name": "Staker",
            "nodeType": "StructDefinition",
            "scope": 9740,
            "src": "1212:189:29",
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 9178,
            "name": "stakers",
            "nodeType": "VariableDeclaration",
            "scope": 9740,
            "src": "1455:41:29",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_mapping$_t_address_$_t_struct$_Staker_$9174_storage_$",
              "typeString": "mapping(address => struct SimpleDAIStaking.Staker)"
            },
            "typeName": {
              "id": 9177,
              "keyType": {
                "id": 9175,
                "name": "address",
                "nodeType": "ElementaryTypeName",
                "src": "1463:7:29",
                "typeDescriptions": {
                  "typeIdentifier": "t_address",
                  "typeString": "address"
                }
              },
              "nodeType": "Mapping",
              "src": "1455:26:29",
              "typeDescriptions": {
                "typeIdentifier": "t_mapping$_t_address_$_t_struct$_Staker_$9174_storage_$",
                "typeString": "mapping(address => struct SimpleDAIStaking.Staker)"
              },
              "valueType": {
                "contractScope": null,
                "id": 9176,
                "name": "Staker",
                "nodeType": "UserDefinedTypeName",
                "referencedDeclaration": 9174,
                "src": "1474:6:29",
                "typeDescriptions": {
                  "typeIdentifier": "t_struct$_Staker_$9174_storage_ptr",
                  "typeString": "struct SimpleDAIStaking.Staker"
                }
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "anonymous": false,
            "documentation": null,
            "id": 9184,
            "name": "DAIStaked",
            "nodeType": "EventDefinition",
            "parameters": {
              "id": 9183,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9180,
                  "indexed": true,
                  "name": "staker",
                  "nodeType": "VariableDeclaration",
                  "scope": 9184,
                  "src": "1608:22:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 9179,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "1608:7:29",
                    "stateMutability": "nonpayable",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9182,
                  "indexed": false,
                  "name": "daiValue",
                  "nodeType": "VariableDeclaration",
                  "scope": 9184,
                  "src": "1684:16:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9181,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "1684:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "1568:138:29"
            },
            "src": "1553:154:29"
          },
          {
            "anonymous": false,
            "documentation": null,
            "id": 9192,
            "name": "DAIStakeWithdraw",
            "nodeType": "EventDefinition",
            "parameters": {
              "id": 9191,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9186,
                  "indexed": true,
                  "name": "staker",
                  "nodeType": "VariableDeclaration",
                  "scope": 9192,
                  "src": "1841:22:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 9185,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "1841:7:29",
                    "stateMutability": "nonpayable",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9188,
                  "indexed": false,
                  "name": "daiValue",
                  "nodeType": "VariableDeclaration",
                  "scope": 9192,
                  "src": "1922:16:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9187,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "1922:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9190,
                  "indexed": false,
                  "name": "daiActual",
                  "nodeType": "VariableDeclaration",
                  "scope": 9192,
                  "src": "1997:17:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9189,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "1997:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "1784:236:29"
            },
            "src": "1762:259:29"
          },
          {
            "anonymous": false,
            "documentation": null,
            "id": 9202,
            "name": "InterestCollected",
            "nodeType": "EventDefinition",
            "parameters": {
              "id": 9201,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9194,
                  "indexed": false,
                  "name": "recipient",
                  "nodeType": "VariableDeclaration",
                  "scope": 9202,
                  "src": "2144:17:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 9193,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "2144:7:29",
                    "stateMutability": "nonpayable",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9196,
                  "indexed": false,
                  "name": "cdaiValue",
                  "nodeType": "VariableDeclaration",
                  "scope": 9202,
                  "src": "2225:17:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9195,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "2225:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9198,
                  "indexed": false,
                  "name": "daiValue",
                  "nodeType": "VariableDeclaration",
                  "scope": 9202,
                  "src": "2306:16:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9197,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "2306:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9200,
                  "indexed": false,
                  "name": "daiPrecisionLoss",
                  "nodeType": "VariableDeclaration",
                  "scope": 9202,
                  "src": "2389:24:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9199,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "2389:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "2094:325:29"
            },
            "src": "2071:349:29"
          },
          {
            "constant": false,
            "id": 9204,
            "name": "dai",
            "nodeType": "VariableDeclaration",
            "scope": 9740,
            "src": "2451:16:29",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_contract$_ERC20_$21849",
              "typeString": "contract ERC20"
            },
            "typeName": {
              "contractScope": null,
              "id": 9203,
              "name": "ERC20",
              "nodeType": "UserDefinedTypeName",
              "referencedDeclaration": 21849,
              "src": "2451:5:29",
              "typeDescriptions": {
                "typeIdentifier": "t_contract$_ERC20_$21849",
                "typeString": "contract ERC20"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 9206,
            "name": "cDai",
            "nodeType": "VariableDeclaration",
            "scope": 9740,
            "src": "2500:18:29",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_contract$_cERC20_$9160",
              "typeString": "contract cERC20"
            },
            "typeName": {
              "contractScope": null,
              "id": 9205,
              "name": "cERC20",
              "nodeType": "UserDefinedTypeName",
              "referencedDeclaration": 9160,
              "src": "2500:6:29",
              "typeDescriptions": {
                "typeIdentifier": "t_contract$_cERC20_$9160",
                "typeString": "contract cERC20"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 9208,
            "name": "blockInterval",
            "nodeType": "VariableDeclaration",
            "scope": 9740,
            "src": "2665:28:29",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_uint256",
              "typeString": "uint256"
            },
            "typeName": {
              "id": 9207,
              "name": "uint256",
              "nodeType": "ElementaryTypeName",
              "src": "2665:7:29",
              "typeDescriptions": {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 9210,
            "name": "lastUBICollection",
            "nodeType": "VariableDeclaration",
            "scope": 9740,
            "src": "2784:32:29",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_uint256",
              "typeString": "uint256"
            },
            "typeName": {
              "id": 9209,
              "name": "uint256",
              "nodeType": "ElementaryTypeName",
              "src": "2784:7:29",
              "typeDescriptions": {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 9213,
            "name": "totalStaked",
            "nodeType": "VariableDeclaration",
            "scope": 9740,
            "src": "2874:30:29",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_uint256",
              "typeString": "uint256"
            },
            "typeName": {
              "id": 9211,
              "name": "uint256",
              "nodeType": "ElementaryTypeName",
              "src": "2874:7:29",
              "typeDescriptions": {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              }
            },
            "value": {
              "argumentTypes": null,
              "hexValue": "30",
              "id": 9212,
              "isConstant": false,
              "isLValue": false,
              "isPure": true,
              "kind": "number",
              "lValueRequested": false,
              "nodeType": "Literal",
              "src": "2903:1:29",
              "subdenomination": null,
              "typeDescriptions": {
                "typeIdentifier": "t_rational_0_by_1",
                "typeString": "int_const 0"
              },
              "value": "0"
            },
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 9216,
            "name": "avgInterestDonatedRatio",
            "nodeType": "VariableDeclaration",
            "scope": 9740,
            "src": "3062:43:29",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_uint32",
              "typeString": "uint32"
            },
            "typeName": {
              "id": 9214,
              "name": "uint32",
              "nodeType": "ElementaryTypeName",
              "src": "3062:6:29",
              "typeDescriptions": {
                "typeIdentifier": "t_uint32",
                "typeString": "uint32"
              }
            },
            "value": {
              "argumentTypes": null,
              "hexValue": "316536",
              "id": 9215,
              "isConstant": false,
              "isLValue": false,
              "isPure": true,
              "kind": "number",
              "lValueRequested": false,
              "nodeType": "Literal",
              "src": "3102:3:29",
              "subdenomination": null,
              "typeDescriptions": {
                "typeIdentifier": "t_rational_1000000_by_1",
                "typeString": "int_const 1000000"
              },
              "value": "1e6"
            },
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 9218,
            "name": "fundManager",
            "nodeType": "VariableDeclaration",
            "scope": 9740,
            "src": "3160:26:29",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_address",
              "typeString": "address"
            },
            "typeName": {
              "id": 9217,
              "name": "address",
              "nodeType": "ElementaryTypeName",
              "src": "3160:7:29",
              "stateMutability": "nonpayable",
              "typeDescriptions": {
                "typeIdentifier": "t_address",
                "typeString": "address"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "body": {
              "id": 9229,
              "nodeType": "Block",
              "src": "3218:103:29",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "commonType": {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        },
                        "id": 9224,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "leftExpression": {
                          "argumentTypes": null,
                          "expression": {
                            "argumentTypes": null,
                            "id": 9221,
                            "name": "msg",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 22171,
                            "src": "3236:3:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_magic_message",
                              "typeString": "msg"
                            }
                          },
                          "id": 9222,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "memberName": "sender",
                          "nodeType": "MemberAccess",
                          "referencedDeclaration": null,
                          "src": "3236:10:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_address_payable",
                            "typeString": "address payable"
                          }
                        },
                        "nodeType": "BinaryOperation",
                        "operator": "==",
                        "rightExpression": {
                          "argumentTypes": null,
                          "id": 9223,
                          "name": "fundManager",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9218,
                          "src": "3250:11:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_address",
                            "typeString": "address"
                          }
                        },
                        "src": "3236:25:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "hexValue": "4f6e6c792046756e644d616e616765722063616e2063616c6c2074686973206d6574686f64",
                        "id": 9225,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "3263:39:29",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_8659903c14beb1decb5cde807aae2b42823801f7a2ec9f1cb2d42f84ff652fab",
                          "typeString": "literal_string \"Only FundManager can call this method\""
                        },
                        "value": "Only FundManager can call this method"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        {
                          "typeIdentifier": "t_stringliteral_8659903c14beb1decb5cde807aae2b42823801f7a2ec9f1cb2d42f84ff652fab",
                          "typeString": "literal_string \"Only FundManager can call this method\""
                        }
                      ],
                      "id": 9220,
                      "name": "require",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [
                        22174,
                        22175
                      ],
                      "referencedDeclaration": 22175,
                      "src": "3228:7:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                        "typeString": "function (bool,string memory) pure"
                      }
                    },
                    "id": 9226,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "3228:75:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 9227,
                  "nodeType": "ExpressionStatement",
                  "src": "3228:75:29"
                },
                {
                  "id": 9228,
                  "nodeType": "PlaceholderStatement",
                  "src": "3313:1:29"
                }
              ]
            },
            "documentation": null,
            "id": 9230,
            "name": "onlyFundManager",
            "nodeType": "ModifierDefinition",
            "parameters": {
              "id": 9219,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "3218:0:29"
            },
            "src": "3193:128:29",
            "visibility": "internal"
          },
          {
            "body": {
              "id": 9283,
              "nodeType": "Block",
              "src": "3933:294:29",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 9253,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 9249,
                      "name": "dai",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9204,
                      "src": "3943:3:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_contract$_ERC20_$21849",
                        "typeString": "contract ERC20"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 9251,
                          "name": "_dai",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9232,
                          "src": "3955:4:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_address",
                            "typeString": "address"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_address",
                            "typeString": "address"
                          }
                        ],
                        "id": 9250,
                        "name": "ERC20",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 21849,
                        "src": "3949:5:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_type$_t_contract$_ERC20_$21849_$",
                          "typeString": "type(contract ERC20)"
                        }
                      },
                      "id": 9252,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "typeConversion",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "3949:11:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_contract$_ERC20_$21849",
                        "typeString": "contract ERC20"
                      }
                    },
                    "src": "3943:17:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_contract$_ERC20_$21849",
                      "typeString": "contract ERC20"
                    }
                  },
                  "id": 9254,
                  "nodeType": "ExpressionStatement",
                  "src": "3943:17:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 9259,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 9255,
                      "name": "cDai",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9206,
                      "src": "3970:4:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_contract$_cERC20_$9160",
                        "typeString": "contract cERC20"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 9257,
                          "name": "_cDai",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9234,
                          "src": "3984:5:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_address",
                            "typeString": "address"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_address",
                            "typeString": "address"
                          }
                        ],
                        "id": 9256,
                        "name": "cERC20",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9160,
                        "src": "3977:6:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_type$_t_contract$_cERC20_$9160_$",
                          "typeString": "type(contract cERC20)"
                        }
                      },
                      "id": 9258,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "typeConversion",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "3977:13:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_contract$_cERC20_$9160",
                        "typeString": "contract cERC20"
                      }
                    },
                    "src": "3970:20:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_contract$_cERC20_$9160",
                      "typeString": "contract cERC20"
                    }
                  },
                  "id": 9260,
                  "nodeType": "ExpressionStatement",
                  "src": "3970:20:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 9263,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 9261,
                      "name": "blockInterval",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9208,
                      "src": "4000:13:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "id": 9262,
                      "name": "_blockInterval",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9238,
                      "src": "4016:14:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "4000:30:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 9264,
                  "nodeType": "ExpressionStatement",
                  "src": "4000:30:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 9271,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 9265,
                      "name": "lastUBICollection",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9210,
                      "src": "4040:17:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 9269,
                          "name": "blockInterval",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9208,
                          "src": "4077:13:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        ],
                        "expression": {
                          "argumentTypes": null,
                          "expression": {
                            "argumentTypes": null,
                            "id": 9266,
                            "name": "block",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 22161,
                            "src": "4060:5:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_magic_block",
                              "typeString": "block"
                            }
                          },
                          "id": 9267,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "memberName": "number",
                          "nodeType": "MemberAccess",
                          "referencedDeclaration": null,
                          "src": "4060:12:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "id": 9268,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "div",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 21239,
                        "src": "4060:16:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
                          "typeString": "function (uint256,uint256) pure returns (uint256)"
                        }
                      },
                      "id": 9270,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "functionCall",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "4060:31:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "4040:51:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 9272,
                  "nodeType": "ExpressionStatement",
                  "src": "4040:51:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 9275,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 9273,
                      "name": "fundManager",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9218,
                      "src": "4101:11:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "id": 9274,
                      "name": "_fundManager",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9236,
                      "src": "4115:12:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "src": "4101:26:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "id": 9276,
                  "nodeType": "ExpressionStatement",
                  "src": "4101:26:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "id": 9279,
                            "name": "avatar",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 1281,
                            "src": "4212:6:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_contract$_Avatar_$12705",
                              "typeString": "contract Avatar"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_contract$_Avatar_$12705",
                              "typeString": "contract Avatar"
                            }
                          ],
                          "id": 9278,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "lValueRequested": false,
                          "nodeType": "ElementaryTypeNameExpression",
                          "src": "4204:7:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_address_$",
                            "typeString": "type(address)"
                          },
                          "typeName": "address"
                        },
                        "id": 9280,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "typeConversion",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "4204:15:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_address_payable",
                          "typeString": "address payable"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_address_payable",
                          "typeString": "address payable"
                        }
                      ],
                      "id": 9277,
                      "name": "addPauser",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 20905,
                      "src": "4194:9:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$",
                        "typeString": "function (address)"
                      }
                    },
                    "id": 9281,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "4194:26:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 9282,
                  "nodeType": "ExpressionStatement",
                  "src": "4194:26:29"
                }
              ]
            },
            "documentation": "@dev Constructor\n@param _dai The address of DAI\n@param _cDai The address of cDAI\n@param _fundManager The address of the fund manager contract\n@param _blockInterval How many blocks should be passed before the next execution of `collectUBIInterest`\n@param _avatar The avatar of the DAO\n@param _identity The identity contract",
            "id": 9284,
            "implemented": true,
            "kind": "constructor",
            "modifiers": [
              {
                "arguments": [
                  {
                    "argumentTypes": null,
                    "id": 9245,
                    "name": "_identity",
                    "nodeType": "Identifier",
                    "overloadedDeclarations": [],
                    "referencedDeclaration": 9242,
                    "src": "3913:9:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_contract$_Identity_$2380",
                      "typeString": "contract Identity"
                    }
                  },
                  {
                    "argumentTypes": null,
                    "id": 9246,
                    "name": "_avatar",
                    "nodeType": "Identifier",
                    "overloadedDeclarations": [],
                    "referencedDeclaration": 9240,
                    "src": "3924:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_contract$_Avatar_$12705",
                      "typeString": "contract Avatar"
                    }
                  }
                ],
                "id": 9247,
                "modifierName": {
                  "argumentTypes": null,
                  "id": 9244,
                  "name": "FeelessScheme",
                  "nodeType": "Identifier",
                  "overloadedDeclarations": [],
                  "referencedDeclaration": 1227,
                  "src": "3899:13:29",
                  "typeDescriptions": {
                    "typeIdentifier": "t_type$_t_contract$_FeelessScheme_$1227_$",
                    "typeString": "type(contract FeelessScheme)"
                  }
                },
                "nodeType": "ModifierInvocation",
                "src": "3899:33:29"
              }
            ],
            "name": "",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9243,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9232,
                  "name": "_dai",
                  "nodeType": "VariableDeclaration",
                  "scope": 9284,
                  "src": "3736:12:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 9231,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "3736:7:29",
                    "stateMutability": "nonpayable",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9234,
                  "name": "_cDai",
                  "nodeType": "VariableDeclaration",
                  "scope": 9284,
                  "src": "3758:13:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 9233,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "3758:7:29",
                    "stateMutability": "nonpayable",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9236,
                  "name": "_fundManager",
                  "nodeType": "VariableDeclaration",
                  "scope": 9284,
                  "src": "3781:20:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 9235,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "3781:7:29",
                    "stateMutability": "nonpayable",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9238,
                  "name": "_blockInterval",
                  "nodeType": "VariableDeclaration",
                  "scope": 9284,
                  "src": "3811:22:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9237,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "3811:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9240,
                  "name": "_avatar",
                  "nodeType": "VariableDeclaration",
                  "scope": 9284,
                  "src": "3843:14:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_contract$_Avatar_$12705",
                    "typeString": "contract Avatar"
                  },
                  "typeName": {
                    "contractScope": null,
                    "id": 9239,
                    "name": "Avatar",
                    "nodeType": "UserDefinedTypeName",
                    "referencedDeclaration": 12705,
                    "src": "3843:6:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_contract$_Avatar_$12705",
                      "typeString": "contract Avatar"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9242,
                  "name": "_identity",
                  "nodeType": "VariableDeclaration",
                  "scope": 9284,
                  "src": "3867:18:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_contract$_Identity_$2380",
                    "typeString": "contract Identity"
                  },
                  "typeName": {
                    "contractScope": null,
                    "id": 9241,
                    "name": "Identity",
                    "nodeType": "UserDefinedTypeName",
                    "referencedDeclaration": 2380,
                    "src": "3867:8:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_contract$_Identity_$2380",
                      "typeString": "contract Identity"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "3726:165:29"
            },
            "returnParameters": {
              "id": 9248,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "3933:0:29"
            },
            "scope": 9740,
            "src": "3715:512:29",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "public"
          },
          {
            "body": {
              "id": 9295,
              "nodeType": "Block",
              "src": "4439:43:29",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 9293,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 9291,
                      "name": "fundManager",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9218,
                      "src": "4449:11:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "id": 9292,
                      "name": "_fundManager",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9286,
                      "src": "4463:12:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "src": "4449:26:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "id": 9294,
                  "nodeType": "ExpressionStatement",
                  "src": "4449:26:29"
                }
              ]
            },
            "documentation": "@dev Allows the DAO to change the fund manager contract address\n@param _fundManager Address of the new contract",
            "id": 9296,
            "implemented": true,
            "kind": "function",
            "modifiers": [
              {
                "arguments": null,
                "id": 9289,
                "modifierName": {
                  "argumentTypes": null,
                  "id": 9288,
                  "name": "onlyAvatar",
                  "nodeType": "Identifier",
                  "overloadedDeclarations": [],
                  "referencedDeclaration": 1325,
                  "src": "4428:10:29",
                  "typeDescriptions": {
                    "typeIdentifier": "t_modifier$__$",
                    "typeString": "modifier ()"
                  }
                },
                "nodeType": "ModifierInvocation",
                "src": "4428:10:29"
              }
            ],
            "name": "setFundManager",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9287,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9286,
                  "name": "_fundManager",
                  "nodeType": "VariableDeclaration",
                  "scope": 9296,
                  "src": "4399:20:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 9285,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "4399:7:29",
                    "stateMutability": "nonpayable",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "4398:22:29"
            },
            "returnParameters": {
              "id": 9290,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "4439:0:29"
            },
            "scope": 9740,
            "src": "4375:107:29",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "public"
          },
          {
            "body": {
              "id": 9390,
              "nodeType": "Block",
              "src": "4812:1025:29",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "commonType": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        },
                        "id": 9306,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "leftExpression": {
                          "argumentTypes": null,
                          "id": 9304,
                          "name": "_amount",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9298,
                          "src": "4830:7:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "nodeType": "BinaryOperation",
                        "operator": ">",
                        "rightExpression": {
                          "argumentTypes": null,
                          "hexValue": "30",
                          "id": 9305,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "kind": "number",
                          "lValueRequested": false,
                          "nodeType": "Literal",
                          "src": "4840:1:29",
                          "subdenomination": null,
                          "typeDescriptions": {
                            "typeIdentifier": "t_rational_0_by_1",
                            "typeString": "int_const 0"
                          },
                          "value": "0"
                        },
                        "src": "4830:11:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "hexValue": "596f75206e65656420746f207374616b65206120706f73697469766520746f6b656e20616d6f756e74",
                        "id": 9307,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "4843:43:29",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_0df2c7e58c395cb8df3c21ef84be33d1d8ff5cbf2a8b2cf1fa7931eeed13da62",
                          "typeString": "literal_string \"You need to stake a positive token amount\""
                        },
                        "value": "You need to stake a positive token amount"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        {
                          "typeIdentifier": "t_stringliteral_0df2c7e58c395cb8df3c21ef84be33d1d8ff5cbf2a8b2cf1fa7931eeed13da62",
                          "typeString": "literal_string \"You need to stake a positive token amount\""
                        }
                      ],
                      "id": 9303,
                      "name": "require",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [
                        22174,
                        22175
                      ],
                      "referencedDeclaration": 22175,
                      "src": "4822:7:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                        "typeString": "function (bool,string memory) pure"
                      }
                    },
                    "id": 9308,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "4822:65:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 9309,
                  "nodeType": "ExpressionStatement",
                  "src": "4822:65:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "commonType": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        "id": 9321,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "leftExpression": {
                          "argumentTypes": null,
                          "arguments": [
                            {
                              "argumentTypes": null,
                              "expression": {
                                "argumentTypes": null,
                                "id": 9313,
                                "name": "msg",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 22171,
                                "src": "4935:3:29",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_magic_message",
                                  "typeString": "msg"
                                }
                              },
                              "id": 9314,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "lValueRequested": false,
                              "memberName": "sender",
                              "nodeType": "MemberAccess",
                              "referencedDeclaration": null,
                              "src": "4935:10:29",
                              "typeDescriptions": {
                                "typeIdentifier": "t_address_payable",
                                "typeString": "address payable"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "arguments": [
                                {
                                  "argumentTypes": null,
                                  "id": 9316,
                                  "name": "this",
                                  "nodeType": "Identifier",
                                  "overloadedDeclarations": [],
                                  "referencedDeclaration": 22327,
                                  "src": "4955:4:29",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_contract$_SimpleDAIStaking_$9740",
                                    "typeString": "contract SimpleDAIStaking"
                                  }
                                }
                              ],
                              "expression": {
                                "argumentTypes": [
                                  {
                                    "typeIdentifier": "t_contract$_SimpleDAIStaking_$9740",
                                    "typeString": "contract SimpleDAIStaking"
                                  }
                                ],
                                "id": 9315,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": true,
                                "lValueRequested": false,
                                "nodeType": "ElementaryTypeNameExpression",
                                "src": "4947:7:29",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_type$_t_address_$",
                                  "typeString": "type(address)"
                                },
                                "typeName": "address"
                              },
                              "id": 9317,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "kind": "typeConversion",
                              "lValueRequested": false,
                              "names": [],
                              "nodeType": "FunctionCall",
                              "src": "4947:13:29",
                              "typeDescriptions": {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "id": 9318,
                              "name": "_amount",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 9298,
                              "src": "4962:7:29",
                              "typeDescriptions": {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              }
                            }
                          ],
                          "expression": {
                            "argumentTypes": [
                              {
                                "typeIdentifier": "t_address_payable",
                                "typeString": "address payable"
                              },
                              {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              },
                              {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              }
                            ],
                            "expression": {
                              "argumentTypes": null,
                              "id": 9311,
                              "name": "dai",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 9204,
                              "src": "4918:3:29",
                              "typeDescriptions": {
                                "typeIdentifier": "t_contract$_ERC20_$21849",
                                "typeString": "contract ERC20"
                              }
                            },
                            "id": 9312,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": false,
                            "lValueRequested": false,
                            "memberName": "transferFrom",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": 21578,
                            "src": "4918:16:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$_t_bool_$",
                              "typeString": "function (address,address,uint256) external returns (bool)"
                            }
                          },
                          "id": 9319,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "kind": "functionCall",
                          "lValueRequested": false,
                          "names": [],
                          "nodeType": "FunctionCall",
                          "src": "4918:52:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_bool",
                            "typeString": "bool"
                          }
                        },
                        "nodeType": "BinaryOperation",
                        "operator": "==",
                        "rightExpression": {
                          "argumentTypes": null,
                          "hexValue": "74727565",
                          "id": 9320,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "kind": "bool",
                          "lValueRequested": false,
                          "nodeType": "Literal",
                          "src": "4974:4:29",
                          "subdenomination": null,
                          "typeDescriptions": {
                            "typeIdentifier": "t_bool",
                            "typeString": "bool"
                          },
                          "value": "true"
                        },
                        "src": "4918:60:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "hexValue": "7472616e7366657246726f6d206661696c65642c206d616b65207375726520796f7520617070726f76656420444149207472616e73666572",
                        "id": 9322,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "4992:58:29",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_ee07915d88e147dbd0474d1f4b7dd5b98a6778f07e832106ffd695a46b406d6e",
                          "typeString": "literal_string \"transferFrom failed, make sure you approved DAI transfer\""
                        },
                        "value": "transferFrom failed, make sure you approved DAI transfer"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        {
                          "typeIdentifier": "t_stringliteral_ee07915d88e147dbd0474d1f4b7dd5b98a6778f07e832106ffd695a46b406d6e",
                          "typeString": "literal_string \"transferFrom failed, make sure you approved DAI transfer\""
                        }
                      ],
                      "id": 9310,
                      "name": "require",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [
                        22174,
                        22175
                      ],
                      "referencedDeclaration": 22175,
                      "src": "4897:7:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                        "typeString": "function (bool,string memory) pure"
                      }
                    },
                    "id": 9323,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "4897:163:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 9324,
                  "nodeType": "ExpressionStatement",
                  "src": "4897:163:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "id": 9329,
                            "name": "cDai",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 9206,
                            "src": "5131:4:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_contract$_cERC20_$9160",
                              "typeString": "contract cERC20"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_contract$_cERC20_$9160",
                              "typeString": "contract cERC20"
                            }
                          ],
                          "id": 9328,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "lValueRequested": false,
                          "nodeType": "ElementaryTypeNameExpression",
                          "src": "5123:7:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_address_$",
                            "typeString": "type(address)"
                          },
                          "typeName": "address"
                        },
                        "id": 9330,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "typeConversion",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "5123:13:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 9331,
                        "name": "_amount",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9298,
                        "src": "5138:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        },
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      ],
                      "expression": {
                        "argumentTypes": null,
                        "id": 9325,
                        "name": "dai",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9204,
                        "src": "5111:3:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_contract$_ERC20_$21849",
                          "typeString": "contract ERC20"
                        }
                      },
                      "id": 9327,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "approve",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 21529,
                      "src": "5111:11:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$",
                        "typeString": "function (address,uint256) external returns (bool)"
                      }
                    },
                    "id": 9332,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "5111:35:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "id": 9333,
                  "nodeType": "ExpressionStatement",
                  "src": "5111:35:29"
                },
                {
                  "assignments": [
                    9335
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 9335,
                      "name": "res",
                      "nodeType": "VariableDeclaration",
                      "scope": 9390,
                      "src": "5181:11:29",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 9334,
                        "name": "uint256",
                        "nodeType": "ElementaryTypeName",
                        "src": "5181:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 9340,
                  "initialValue": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "id": 9338,
                        "name": "_amount",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9298,
                        "src": "5205:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      ],
                      "expression": {
                        "argumentTypes": null,
                        "id": 9336,
                        "name": "cDai",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9206,
                        "src": "5195:4:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_contract$_cERC20_$9160",
                          "typeString": "contract cERC20"
                        }
                      },
                      "id": 9337,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "mint",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 9126,
                      "src": "5195:9:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_external_nonpayable$_t_uint256_$returns$_t_uint256_$",
                        "typeString": "function (uint256) external returns (uint256)"
                      }
                    },
                    "id": 9339,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "5195:18:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "5181:32:29"
                },
                {
                  "condition": {
                    "argumentTypes": null,
                    "commonType": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    },
                    "id": 9343,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftExpression": {
                      "argumentTypes": null,
                      "id": 9341,
                      "name": "res",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9335,
                      "src": "5402:3:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "BinaryOperation",
                    "operator": ">",
                    "rightExpression": {
                      "argumentTypes": null,
                      "hexValue": "30",
                      "id": 9342,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": true,
                      "kind": "number",
                      "lValueRequested": false,
                      "nodeType": "Literal",
                      "src": "5408:1:29",
                      "subdenomination": null,
                      "typeDescriptions": {
                        "typeIdentifier": "t_rational_0_by_1",
                        "typeString": "int_const 0"
                      },
                      "value": "0"
                    },
                    "src": "5402:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "falseBody": null,
                  "id": 9352,
                  "nodeType": "IfStatement",
                  "src": "5398:94:29",
                  "trueBody": {
                    "id": 9351,
                    "nodeType": "Block",
                    "src": "5411:81:29",
                    "statements": [
                      {
                        "expression": {
                          "argumentTypes": null,
                          "arguments": [
                            {
                              "argumentTypes": null,
                              "commonType": {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              },
                              "id": 9347,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "lValueRequested": false,
                              "leftExpression": {
                                "argumentTypes": null,
                                "id": 9345,
                                "name": "res",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 9335,
                                "src": "5433:3:29",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_uint256",
                                  "typeString": "uint256"
                                }
                              },
                              "nodeType": "BinaryOperation",
                              "operator": "==",
                              "rightExpression": {
                                "argumentTypes": null,
                                "hexValue": "30",
                                "id": 9346,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": true,
                                "kind": "number",
                                "lValueRequested": false,
                                "nodeType": "Literal",
                                "src": "5440:1:29",
                                "subdenomination": null,
                                "typeDescriptions": {
                                  "typeIdentifier": "t_rational_0_by_1",
                                  "typeString": "int_const 0"
                                },
                                "value": "0"
                              },
                              "src": "5433:8:29",
                              "typeDescriptions": {
                                "typeIdentifier": "t_bool",
                                "typeString": "bool"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "hexValue": "4d696e74696e672063446169206661696c65642c2066756e64732072657475726e6564",
                              "id": 9348,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": true,
                              "kind": "string",
                              "lValueRequested": false,
                              "nodeType": "Literal",
                              "src": "5443:37:29",
                              "subdenomination": null,
                              "typeDescriptions": {
                                "typeIdentifier": "t_stringliteral_9fba825e72dafc705b289a19c5027021048dd7f2ebe3c823d265b59e8a41b98f",
                                "typeString": "literal_string \"Minting cDai failed, funds returned\""
                              },
                              "value": "Minting cDai failed, funds returned"
                            }
                          ],
                          "expression": {
                            "argumentTypes": [
                              {
                                "typeIdentifier": "t_bool",
                                "typeString": "bool"
                              },
                              {
                                "typeIdentifier": "t_stringliteral_9fba825e72dafc705b289a19c5027021048dd7f2ebe3c823d265b59e8a41b98f",
                                "typeString": "literal_string \"Minting cDai failed, funds returned\""
                              }
                            ],
                            "id": 9344,
                            "name": "require",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [
                              22174,
                              22175
                            ],
                            "referencedDeclaration": 22175,
                            "src": "5425:7:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                              "typeString": "function (bool,string memory) pure"
                            }
                          },
                          "id": 9349,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "kind": "functionCall",
                          "lValueRequested": false,
                          "names": [],
                          "nodeType": "FunctionCall",
                          "src": "5425:56:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_tuple$__$",
                            "typeString": "tuple()"
                          }
                        },
                        "id": 9350,
                        "nodeType": "ExpressionStatement",
                        "src": "5425:56:29"
                      }
                    ]
                  }
                },
                {
                  "assignments": [
                    9354
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 9354,
                      "name": "staker",
                      "nodeType": "VariableDeclaration",
                      "scope": 9390,
                      "src": "5539:21:29",
                      "stateVariable": false,
                      "storageLocation": "storage",
                      "typeDescriptions": {
                        "typeIdentifier": "t_struct$_Staker_$9174_storage_ptr",
                        "typeString": "struct SimpleDAIStaking.Staker"
                      },
                      "typeName": {
                        "contractScope": null,
                        "id": 9353,
                        "name": "Staker",
                        "nodeType": "UserDefinedTypeName",
                        "referencedDeclaration": 9174,
                        "src": "5539:6:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_struct$_Staker_$9174_storage_ptr",
                          "typeString": "struct SimpleDAIStaking.Staker"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 9359,
                  "initialValue": {
                    "argumentTypes": null,
                    "baseExpression": {
                      "argumentTypes": null,
                      "id": 9355,
                      "name": "stakers",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9178,
                      "src": "5563:7:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_mapping$_t_address_$_t_struct$_Staker_$9174_storage_$",
                        "typeString": "mapping(address => struct SimpleDAIStaking.Staker storage ref)"
                      }
                    },
                    "id": 9358,
                    "indexExpression": {
                      "argumentTypes": null,
                      "expression": {
                        "argumentTypes": null,
                        "id": 9356,
                        "name": "msg",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 22171,
                        "src": "5571:3:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_magic_message",
                          "typeString": "msg"
                        }
                      },
                      "id": 9357,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "sender",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": null,
                      "src": "5571:10:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address_payable",
                        "typeString": "address payable"
                      }
                    },
                    "isConstant": false,
                    "isLValue": true,
                    "isPure": false,
                    "lValueRequested": false,
                    "nodeType": "IndexAccess",
                    "src": "5563:19:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_struct$_Staker_$9174_storage",
                      "typeString": "struct SimpleDAIStaking.Staker storage ref"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "5539:43:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 9368,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "expression": {
                        "argumentTypes": null,
                        "id": 9360,
                        "name": "staker",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9354,
                        "src": "5592:6:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_struct$_Staker_$9174_storage_ptr",
                          "typeString": "struct SimpleDAIStaking.Staker storage pointer"
                        }
                      },
                      "id": 9362,
                      "isConstant": false,
                      "isLValue": true,
                      "isPure": false,
                      "lValueRequested": true,
                      "memberName": "stakedDAI",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 9171,
                      "src": "5592:16:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 9366,
                          "name": "_amount",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9298,
                          "src": "5632:7:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        ],
                        "expression": {
                          "argumentTypes": null,
                          "expression": {
                            "argumentTypes": null,
                            "id": 9363,
                            "name": "staker",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 9354,
                            "src": "5611:6:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_struct$_Staker_$9174_storage_ptr",
                              "typeString": "struct SimpleDAIStaking.Staker storage pointer"
                            }
                          },
                          "id": 9364,
                          "isConstant": false,
                          "isLValue": true,
                          "isPure": false,
                          "lValueRequested": false,
                          "memberName": "stakedDAI",
                          "nodeType": "MemberAccess",
                          "referencedDeclaration": 9171,
                          "src": "5611:16:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "id": 9365,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "add",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 21287,
                        "src": "5611:20:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
                          "typeString": "function (uint256,uint256) pure returns (uint256)"
                        }
                      },
                      "id": 9367,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "functionCall",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "5611:29:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "5592:48:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 9369,
                  "nodeType": "ExpressionStatement",
                  "src": "5592:48:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 9375,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "expression": {
                        "argumentTypes": null,
                        "id": 9370,
                        "name": "staker",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9354,
                        "src": "5650:6:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_struct$_Staker_$9174_storage_ptr",
                          "typeString": "struct SimpleDAIStaking.Staker storage pointer"
                        }
                      },
                      "id": 9372,
                      "isConstant": false,
                      "isLValue": true,
                      "isPure": false,
                      "lValueRequested": true,
                      "memberName": "lastStake",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 9173,
                      "src": "5650:16:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "expression": {
                        "argumentTypes": null,
                        "id": 9373,
                        "name": "block",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 22161,
                        "src": "5669:5:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_magic_block",
                          "typeString": "block"
                        }
                      },
                      "id": 9374,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "number",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": null,
                      "src": "5669:12:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "5650:31:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 9376,
                  "nodeType": "ExpressionStatement",
                  "src": "5650:31:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 9382,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 9377,
                      "name": "totalStaked",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9213,
                      "src": "5746:11:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 9380,
                          "name": "_amount",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9298,
                          "src": "5776:7:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        ],
                        "expression": {
                          "argumentTypes": null,
                          "id": 9378,
                          "name": "totalStaked",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9213,
                          "src": "5760:11:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "id": 9379,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "add",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 21287,
                        "src": "5760:15:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
                          "typeString": "function (uint256,uint256) pure returns (uint256)"
                        }
                      },
                      "id": 9381,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "functionCall",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "5760:24:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "5746:38:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 9383,
                  "nodeType": "ExpressionStatement",
                  "src": "5746:38:29"
                },
                {
                  "eventCall": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "expression": {
                          "argumentTypes": null,
                          "id": 9385,
                          "name": "msg",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 22171,
                          "src": "5810:3:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_magic_message",
                            "typeString": "msg"
                          }
                        },
                        "id": 9386,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "sender",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": null,
                        "src": "5810:10:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_address_payable",
                          "typeString": "address payable"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 9387,
                        "name": "_amount",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9298,
                        "src": "5822:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_address_payable",
                          "typeString": "address payable"
                        },
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      ],
                      "id": 9384,
                      "name": "DAIStaked",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9184,
                      "src": "5800:9:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$returns$__$",
                        "typeString": "function (address,uint256)"
                      }
                    },
                    "id": 9388,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "5800:30:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 9389,
                  "nodeType": "EmitStatement",
                  "src": "5795:35:29"
                }
              ]
            },
            "documentation": "@dev Allows a staker to deposit DAI tokens. Notice that `approve` is\nneeded to be executed before the execution of this method.\nCan be executed only when the contract is not paused.\n@param _amount The amount of DAI to stake",
            "id": 9391,
            "implemented": true,
            "kind": "function",
            "modifiers": [
              {
                "arguments": null,
                "id": 9301,
                "modifierName": {
                  "argumentTypes": null,
                  "id": 9300,
                  "name": "whenNotPaused",
                  "nodeType": "Identifier",
                  "overloadedDeclarations": [],
                  "referencedDeclaration": 21068,
                  "src": "4798:13:29",
                  "typeDescriptions": {
                    "typeIdentifier": "t_modifier$__$",
                    "typeString": "modifier ()"
                  }
                },
                "nodeType": "ModifierInvocation",
                "src": "4798:13:29"
              }
            ],
            "name": "stakeDAI",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9299,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9298,
                  "name": "_amount",
                  "nodeType": "VariableDeclaration",
                  "scope": 9391,
                  "src": "4774:15:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9297,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "4774:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "4773:17:29"
            },
            "returnParameters": {
              "id": 9302,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "4812:0:29"
            },
            "scope": 9740,
            "src": "4756:1081:29",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "public"
          },
          {
            "body": {
              "id": 9473,
              "nodeType": "Block",
              "src": "5936:853:29",
              "statements": [
                {
                  "assignments": [
                    9395
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 9395,
                      "name": "staker",
                      "nodeType": "VariableDeclaration",
                      "scope": 9473,
                      "src": "5946:21:29",
                      "stateVariable": false,
                      "storageLocation": "storage",
                      "typeDescriptions": {
                        "typeIdentifier": "t_struct$_Staker_$9174_storage_ptr",
                        "typeString": "struct SimpleDAIStaking.Staker"
                      },
                      "typeName": {
                        "contractScope": null,
                        "id": 9394,
                        "name": "Staker",
                        "nodeType": "UserDefinedTypeName",
                        "referencedDeclaration": 9174,
                        "src": "5946:6:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_struct$_Staker_$9174_storage_ptr",
                          "typeString": "struct SimpleDAIStaking.Staker"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 9400,
                  "initialValue": {
                    "argumentTypes": null,
                    "baseExpression": {
                      "argumentTypes": null,
                      "id": 9396,
                      "name": "stakers",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9178,
                      "src": "5970:7:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_mapping$_t_address_$_t_struct$_Staker_$9174_storage_$",
                        "typeString": "mapping(address => struct SimpleDAIStaking.Staker storage ref)"
                      }
                    },
                    "id": 9399,
                    "indexExpression": {
                      "argumentTypes": null,
                      "expression": {
                        "argumentTypes": null,
                        "id": 9397,
                        "name": "msg",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 22171,
                        "src": "5978:3:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_magic_message",
                          "typeString": "msg"
                        }
                      },
                      "id": 9398,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "sender",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": null,
                      "src": "5978:10:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address_payable",
                        "typeString": "address payable"
                      }
                    },
                    "isConstant": false,
                    "isLValue": true,
                    "isPure": false,
                    "lValueRequested": false,
                    "nodeType": "IndexAccess",
                    "src": "5970:19:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_struct$_Staker_$9174_storage",
                      "typeString": "struct SimpleDAIStaking.Staker storage ref"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "5946:43:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "commonType": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        },
                        "id": 9405,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "leftExpression": {
                          "argumentTypes": null,
                          "expression": {
                            "argumentTypes": null,
                            "id": 9402,
                            "name": "staker",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 9395,
                            "src": "6007:6:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_struct$_Staker_$9174_storage_ptr",
                              "typeString": "struct SimpleDAIStaking.Staker storage pointer"
                            }
                          },
                          "id": 9403,
                          "isConstant": false,
                          "isLValue": true,
                          "isPure": false,
                          "lValueRequested": false,
                          "memberName": "stakedDAI",
                          "nodeType": "MemberAccess",
                          "referencedDeclaration": 9171,
                          "src": "6007:16:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "nodeType": "BinaryOperation",
                        "operator": ">",
                        "rightExpression": {
                          "argumentTypes": null,
                          "hexValue": "30",
                          "id": 9404,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "kind": "number",
                          "lValueRequested": false,
                          "nodeType": "Literal",
                          "src": "6026:1:29",
                          "subdenomination": null,
                          "typeDescriptions": {
                            "typeIdentifier": "t_rational_0_by_1",
                            "typeString": "int_const 0"
                          },
                          "value": "0"
                        },
                        "src": "6007:20:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "hexValue": "4e6f20444149207374616b6564",
                        "id": 9406,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "6029:15:29",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_c7a1c4dcae14020a6de4ccb28b8861c795f9958e1fbdb2ab0fb5dc5d25e10738",
                          "typeString": "literal_string \"No DAI staked\""
                        },
                        "value": "No DAI staked"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        {
                          "typeIdentifier": "t_stringliteral_c7a1c4dcae14020a6de4ccb28b8861c795f9958e1fbdb2ab0fb5dc5d25e10738",
                          "typeString": "literal_string \"No DAI staked\""
                        }
                      ],
                      "id": 9401,
                      "name": "require",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [
                        22174,
                        22175
                      ],
                      "referencedDeclaration": 22175,
                      "src": "5999:7:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                        "typeString": "function (bool,string memory) pure"
                      }
                    },
                    "id": 9407,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "5999:46:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 9408,
                  "nodeType": "ExpressionStatement",
                  "src": "5999:46:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "commonType": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        },
                        "id": 9416,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "leftExpression": {
                          "argumentTypes": null,
                          "arguments": [
                            {
                              "argumentTypes": null,
                              "expression": {
                                "argumentTypes": null,
                                "id": 9412,
                                "name": "staker",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 9395,
                                "src": "6085:6:29",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_struct$_Staker_$9174_storage_ptr",
                                  "typeString": "struct SimpleDAIStaking.Staker storage pointer"
                                }
                              },
                              "id": 9413,
                              "isConstant": false,
                              "isLValue": true,
                              "isPure": false,
                              "lValueRequested": false,
                              "memberName": "stakedDAI",
                              "nodeType": "MemberAccess",
                              "referencedDeclaration": 9171,
                              "src": "6085:16:29",
                              "typeDescriptions": {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              }
                            }
                          ],
                          "expression": {
                            "argumentTypes": [
                              {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              }
                            ],
                            "expression": {
                              "argumentTypes": null,
                              "id": 9410,
                              "name": "cDai",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 9206,
                              "src": "6063:4:29",
                              "typeDescriptions": {
                                "typeIdentifier": "t_contract$_cERC20_$9160",
                                "typeString": "contract cERC20"
                              }
                            },
                            "id": 9411,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": false,
                            "lValueRequested": false,
                            "memberName": "redeemUnderlying",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": 9133,
                            "src": "6063:21:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_function_external_nonpayable$_t_uint256_$returns$_t_uint256_$",
                              "typeString": "function (uint256) external returns (uint256)"
                            }
                          },
                          "id": 9414,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "kind": "functionCall",
                          "lValueRequested": false,
                          "names": [],
                          "nodeType": "FunctionCall",
                          "src": "6063:39:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "nodeType": "BinaryOperation",
                        "operator": "==",
                        "rightExpression": {
                          "argumentTypes": null,
                          "hexValue": "30",
                          "id": 9415,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "kind": "number",
                          "lValueRequested": false,
                          "nodeType": "Literal",
                          "src": "6106:1:29",
                          "subdenomination": null,
                          "typeDescriptions": {
                            "typeIdentifier": "t_rational_0_by_1",
                            "typeString": "int_const 0"
                          },
                          "value": "0"
                        },
                        "src": "6063:44:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "hexValue": "4661696c656420746f2072656465656d2063446169",
                        "id": 9417,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "6109:23:29",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_1f647a2f625cf3b1ea4c7844befd4fe6574e2c7464224cfadaec07f3918cd8a2",
                          "typeString": "literal_string \"Failed to redeem cDai\""
                        },
                        "value": "Failed to redeem cDai"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        {
                          "typeIdentifier": "t_stringliteral_1f647a2f625cf3b1ea4c7844befd4fe6574e2c7464224cfadaec07f3918cd8a2",
                          "typeString": "literal_string \"Failed to redeem cDai\""
                        }
                      ],
                      "id": 9409,
                      "name": "require",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [
                        22174,
                        22175
                      ],
                      "referencedDeclaration": 22175,
                      "src": "6055:7:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                        "typeString": "function (bool,string memory) pure"
                      }
                    },
                    "id": 9418,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "6055:78:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 9419,
                  "nodeType": "ExpressionStatement",
                  "src": "6055:78:29"
                },
                {
                  "assignments": [
                    9421
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 9421,
                      "name": "daiWithdraw",
                      "nodeType": "VariableDeclaration",
                      "scope": 9473,
                      "src": "6143:19:29",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 9420,
                        "name": "uint256",
                        "nodeType": "ElementaryTypeName",
                        "src": "6143:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 9424,
                  "initialValue": {
                    "argumentTypes": null,
                    "expression": {
                      "argumentTypes": null,
                      "id": 9422,
                      "name": "staker",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9395,
                      "src": "6165:6:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_struct$_Staker_$9174_storage_ptr",
                        "typeString": "struct SimpleDAIStaking.Staker storage pointer"
                      }
                    },
                    "id": 9423,
                    "isConstant": false,
                    "isLValue": true,
                    "isPure": false,
                    "lValueRequested": false,
                    "memberName": "stakedDAI",
                    "nodeType": "MemberAccess",
                    "referencedDeclaration": 9171,
                    "src": "6165:16:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "6143:38:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 9429,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "expression": {
                        "argumentTypes": null,
                        "id": 9425,
                        "name": "staker",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9395,
                        "src": "6255:6:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_struct$_Staker_$9174_storage_ptr",
                          "typeString": "struct SimpleDAIStaking.Staker storage pointer"
                        }
                      },
                      "id": 9427,
                      "isConstant": false,
                      "isLValue": true,
                      "isPure": false,
                      "lValueRequested": true,
                      "memberName": "stakedDAI",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 9171,
                      "src": "6255:16:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "hexValue": "30",
                      "id": 9428,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": true,
                      "kind": "number",
                      "lValueRequested": false,
                      "nodeType": "Literal",
                      "src": "6274:1:29",
                      "subdenomination": null,
                      "typeDescriptions": {
                        "typeIdentifier": "t_rational_0_by_1",
                        "typeString": "int_const 0"
                      },
                      "value": "0"
                    },
                    "src": "6255:20:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 9430,
                  "nodeType": "ExpressionStatement",
                  "src": "6255:20:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 9436,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 9431,
                      "name": "totalStaked",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9213,
                      "src": "6286:11:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 9434,
                          "name": "daiWithdraw",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9421,
                          "src": "6316:11:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        ],
                        "expression": {
                          "argumentTypes": null,
                          "id": 9432,
                          "name": "totalStaked",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9213,
                          "src": "6300:11:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "id": 9433,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "sub",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 21263,
                        "src": "6300:15:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
                          "typeString": "function (uint256,uint256) pure returns (uint256)"
                        }
                      },
                      "id": 9435,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "functionCall",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "6300:28:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "6286:42:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 9437,
                  "nodeType": "ExpressionStatement",
                  "src": "6286:42:29"
                },
                {
                  "assignments": [
                    9439
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 9439,
                      "name": "daiActual",
                      "nodeType": "VariableDeclaration",
                      "scope": 9473,
                      "src": "6497:17:29",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 9438,
                        "name": "uint256",
                        "nodeType": "ElementaryTypeName",
                        "src": "6497:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 9446,
                  "initialValue": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "id": 9443,
                            "name": "this",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 22327,
                            "src": "6539:4:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_contract$_SimpleDAIStaking_$9740",
                              "typeString": "contract SimpleDAIStaking"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_contract$_SimpleDAIStaking_$9740",
                              "typeString": "contract SimpleDAIStaking"
                            }
                          ],
                          "id": 9442,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "lValueRequested": false,
                          "nodeType": "ElementaryTypeNameExpression",
                          "src": "6531:7:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_address_$",
                            "typeString": "type(address)"
                          },
                          "typeName": "address"
                        },
                        "id": 9444,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "typeConversion",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "6531:13:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      ],
                      "expression": {
                        "argumentTypes": null,
                        "id": 9440,
                        "name": "dai",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9204,
                        "src": "6517:3:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_contract$_ERC20_$21849",
                          "typeString": "contract ERC20"
                        }
                      },
                      "id": 9441,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "balanceOf",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 21458,
                      "src": "6517:13:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$",
                        "typeString": "function (address) view external returns (uint256)"
                      }
                    },
                    "id": 9445,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "6517:28:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "6497:48:29"
                },
                {
                  "condition": {
                    "argumentTypes": null,
                    "commonType": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    },
                    "id": 9449,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftExpression": {
                      "argumentTypes": null,
                      "id": 9447,
                      "name": "daiActual",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9439,
                      "src": "6559:9:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "BinaryOperation",
                    "operator": "<",
                    "rightExpression": {
                      "argumentTypes": null,
                      "id": 9448,
                      "name": "daiWithdraw",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9421,
                      "src": "6571:11:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "6559:23:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "falseBody": null,
                  "id": 9455,
                  "nodeType": "IfStatement",
                  "src": "6555:77:29",
                  "trueBody": {
                    "id": 9454,
                    "nodeType": "Block",
                    "src": "6584:48:29",
                    "statements": [
                      {
                        "expression": {
                          "argumentTypes": null,
                          "id": 9452,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "leftHandSide": {
                            "argumentTypes": null,
                            "id": 9450,
                            "name": "daiWithdraw",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 9421,
                            "src": "6598:11:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          },
                          "nodeType": "Assignment",
                          "operator": "=",
                          "rightHandSide": {
                            "argumentTypes": null,
                            "id": 9451,
                            "name": "daiActual",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 9439,
                            "src": "6612:9:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          },
                          "src": "6598:23:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "id": 9453,
                        "nodeType": "ExpressionStatement",
                        "src": "6598:23:29"
                      }
                    ]
                  }
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "expression": {
                              "argumentTypes": null,
                              "id": 9459,
                              "name": "msg",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 22171,
                              "src": "6662:3:29",
                              "typeDescriptions": {
                                "typeIdentifier": "t_magic_message",
                                "typeString": "msg"
                              }
                            },
                            "id": 9460,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": false,
                            "lValueRequested": false,
                            "memberName": "sender",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": null,
                            "src": "6662:10:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_address_payable",
                              "typeString": "address payable"
                            }
                          },
                          {
                            "argumentTypes": null,
                            "id": 9461,
                            "name": "daiWithdraw",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 9421,
                            "src": "6674:11:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_address_payable",
                              "typeString": "address payable"
                            },
                            {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          ],
                          "expression": {
                            "argumentTypes": null,
                            "id": 9457,
                            "name": "dai",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 9204,
                            "src": "6649:3:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_contract$_ERC20_$21849",
                              "typeString": "contract ERC20"
                            }
                          },
                          "id": 9458,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "memberName": "transfer",
                          "nodeType": "MemberAccess",
                          "referencedDeclaration": 21493,
                          "src": "6649:12:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$",
                            "typeString": "function (address,uint256) external returns (bool)"
                          }
                        },
                        "id": 9462,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "functionCall",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "6649:37:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "hexValue": "7769746864726177207472616e73666572206661696c6564",
                        "id": 9463,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "6688:26:29",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_58bc929e474c8aeb2e4ca83613053e225f521e498e8deece823d1749bab458d1",
                          "typeString": "literal_string \"withdraw transfer failed\""
                        },
                        "value": "withdraw transfer failed"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        {
                          "typeIdentifier": "t_stringliteral_58bc929e474c8aeb2e4ca83613053e225f521e498e8deece823d1749bab458d1",
                          "typeString": "literal_string \"withdraw transfer failed\""
                        }
                      ],
                      "id": 9456,
                      "name": "require",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [
                        22174,
                        22175
                      ],
                      "referencedDeclaration": 22175,
                      "src": "6641:7:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                        "typeString": "function (bool,string memory) pure"
                      }
                    },
                    "id": 9464,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "6641:74:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 9465,
                  "nodeType": "ExpressionStatement",
                  "src": "6641:74:29"
                },
                {
                  "eventCall": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "expression": {
                          "argumentTypes": null,
                          "id": 9467,
                          "name": "msg",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 22171,
                          "src": "6747:3:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_magic_message",
                            "typeString": "msg"
                          }
                        },
                        "id": 9468,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "sender",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": null,
                        "src": "6747:10:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_address_payable",
                          "typeString": "address payable"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 9469,
                        "name": "daiWithdraw",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9421,
                        "src": "6759:11:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 9470,
                        "name": "daiActual",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9439,
                        "src": "6772:9:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_address_payable",
                          "typeString": "address payable"
                        },
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        },
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      ],
                      "id": 9466,
                      "name": "DAIStakeWithdraw",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9192,
                      "src": "6730:16:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$returns$__$",
                        "typeString": "function (address,uint256,uint256)"
                      }
                    },
                    "id": 9471,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "6730:52:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 9472,
                  "nodeType": "EmitStatement",
                  "src": "6725:57:29"
                }
              ]
            },
            "documentation": "@dev Withdraws the sender staked DAI.",
            "id": 9474,
            "implemented": true,
            "kind": "function",
            "modifiers": [],
            "name": "withdrawStake",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9392,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "5926:2:29"
            },
            "returnParameters": {
              "id": 9393,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "5936:0:29"
            },
            "scope": 9740,
            "src": "5904:885:29",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "public"
          },
          {
            "body": {
              "id": 9505,
              "nodeType": "Block",
              "src": "6977:258:29",
              "statements": [
                {
                  "assignments": [
                    9480
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 9480,
                      "name": "er",
                      "nodeType": "VariableDeclaration",
                      "scope": 9505,
                      "src": "6987:10:29",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 9479,
                        "name": "uint256",
                        "nodeType": "ElementaryTypeName",
                        "src": "6987:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 9484,
                  "initialValue": {
                    "argumentTypes": null,
                    "arguments": [],
                    "expression": {
                      "argumentTypes": [],
                      "expression": {
                        "argumentTypes": null,
                        "id": 9481,
                        "name": "cDai",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9206,
                        "src": "7000:4:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_contract$_cERC20_$9160",
                          "typeString": "contract cERC20"
                        }
                      },
                      "id": 9482,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "exchangeRateStored",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 9143,
                      "src": "7000:23:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_external_view$__$returns$_t_uint256_$",
                        "typeString": "function () view external returns (uint256)"
                      }
                    },
                    "id": 9483,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "7000:25:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "6987:38:29"
                },
                {
                  "assignments": [
                    9486
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 9486,
                      "name": "daiBalance",
                      "nodeType": "VariableDeclaration",
                      "scope": 9505,
                      "src": "7123:18:29",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 9485,
                        "name": "uint256",
                        "nodeType": "ElementaryTypeName",
                        "src": "7123:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 9502,
                  "initialValue": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "hexValue": "3130",
                        "id": 9500,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "number",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "7198:2:29",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_rational_10_by_1",
                          "typeString": "int_const 10"
                        },
                        "value": "10"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_rational_10_by_1",
                          "typeString": "int_const 10"
                        }
                      ],
                      "expression": {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "arguments": [
                              {
                                "argumentTypes": null,
                                "hexValue": "31653130",
                                "id": 9495,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": true,
                                "kind": "number",
                                "lValueRequested": false,
                                "nodeType": "Literal",
                                "src": "7183:4:29",
                                "subdenomination": null,
                                "typeDescriptions": {
                                  "typeIdentifier": "t_rational_10000000000_by_1",
                                  "typeString": "int_const 10000000000"
                                },
                                "value": "1e10"
                              }
                            ],
                            "expression": {
                              "argumentTypes": [
                                {
                                  "typeIdentifier": "t_rational_10000000000_by_1",
                                  "typeString": "int_const 10000000000"
                                }
                              ],
                              "expression": {
                                "argumentTypes": null,
                                "arguments": [
                                  {
                                    "argumentTypes": null,
                                    "arguments": [
                                      {
                                        "argumentTypes": null,
                                        "id": 9491,
                                        "name": "this",
                                        "nodeType": "Identifier",
                                        "overloadedDeclarations": [],
                                        "referencedDeclaration": 22327,
                                        "src": "7172:4:29",
                                        "typeDescriptions": {
                                          "typeIdentifier": "t_contract$_SimpleDAIStaking_$9740",
                                          "typeString": "contract SimpleDAIStaking"
                                        }
                                      }
                                    ],
                                    "expression": {
                                      "argumentTypes": [
                                        {
                                          "typeIdentifier": "t_contract$_SimpleDAIStaking_$9740",
                                          "typeString": "contract SimpleDAIStaking"
                                        }
                                      ],
                                      "id": 9490,
                                      "isConstant": false,
                                      "isLValue": false,
                                      "isPure": true,
                                      "lValueRequested": false,
                                      "nodeType": "ElementaryTypeNameExpression",
                                      "src": "7164:7:29",
                                      "typeDescriptions": {
                                        "typeIdentifier": "t_type$_t_address_$",
                                        "typeString": "type(address)"
                                      },
                                      "typeName": "address"
                                    },
                                    "id": 9492,
                                    "isConstant": false,
                                    "isLValue": false,
                                    "isPure": false,
                                    "kind": "typeConversion",
                                    "lValueRequested": false,
                                    "names": [],
                                    "nodeType": "FunctionCall",
                                    "src": "7164:13:29",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_address",
                                      "typeString": "address"
                                    }
                                  }
                                ],
                                "expression": {
                                  "argumentTypes": [
                                    {
                                      "typeIdentifier": "t_address",
                                      "typeString": "address"
                                    }
                                  ],
                                  "expression": {
                                    "argumentTypes": null,
                                    "id": 9488,
                                    "name": "cDai",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 9206,
                                    "src": "7149:4:29",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_contract$_cERC20_$9160",
                                      "typeString": "contract cERC20"
                                    }
                                  },
                                  "id": 9489,
                                  "isConstant": false,
                                  "isLValue": false,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "memberName": "balanceOf",
                                  "nodeType": "MemberAccess",
                                  "referencedDeclaration": 9150,
                                  "src": "7149:14:29",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$",
                                    "typeString": "function (address) view external returns (uint256)"
                                  }
                                },
                                "id": 9493,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": false,
                                "kind": "functionCall",
                                "lValueRequested": false,
                                "names": [],
                                "nodeType": "FunctionCall",
                                "src": "7149:29:29",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_uint256",
                                  "typeString": "uint256"
                                }
                              },
                              "id": 9494,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "lValueRequested": false,
                              "memberName": "mul",
                              "nodeType": "MemberAccess",
                              "referencedDeclaration": 21215,
                              "src": "7149:33:29",
                              "typeDescriptions": {
                                "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
                                "typeString": "function (uint256,uint256) pure returns (uint256)"
                              }
                            },
                            "id": 9496,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": false,
                            "kind": "functionCall",
                            "lValueRequested": false,
                            "names": [],
                            "nodeType": "FunctionCall",
                            "src": "7149:39:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          },
                          {
                            "argumentTypes": null,
                            "id": 9497,
                            "name": "er",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 9480,
                            "src": "7190:2:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            },
                            {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          ],
                          "id": 9487,
                          "name": "rmul",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 199,
                          "src": "7144:4:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$",
                            "typeString": "function (uint256,uint256) pure returns (uint256)"
                          }
                        },
                        "id": 9498,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "functionCall",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "7144:49:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "id": 9499,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "div",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 21239,
                      "src": "7144:53:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
                        "typeString": "function (uint256,uint256) pure returns (uint256)"
                      }
                    },
                    "id": 9501,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "7144:57:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "7123:78:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 9503,
                    "name": "daiBalance",
                    "nodeType": "Identifier",
                    "overloadedDeclarations": [],
                    "referencedDeclaration": 9486,
                    "src": "7218:10:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "functionReturnParameters": 9478,
                  "id": 9504,
                  "nodeType": "Return",
                  "src": "7211:17:29"
                }
              ]
            },
            "documentation": "@dev Calculates the worth of the staked cDAI tokens in DAI.\n@return (uint256) The worth in DAI",
            "id": 9506,
            "implemented": true,
            "kind": "function",
            "modifiers": [],
            "name": "currentDAIWorth",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9475,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "6944:2:29"
            },
            "returnParameters": {
              "id": 9478,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9477,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 9506,
                  "src": "6968:7:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9476,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "6968:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "6967:9:29"
            },
            "scope": 9740,
            "src": "6920:315:29",
            "stateMutability": "view",
            "superFunction": null,
            "visibility": "public"
          },
          {
            "body": {
              "id": 9582,
              "nodeType": "Block",
              "src": "7615:870:29",
              "statements": [
                {
                  "assignments": [
                    9516
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 9516,
                      "name": "er",
                      "nodeType": "VariableDeclaration",
                      "scope": 9582,
                      "src": "7625:10:29",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 9515,
                        "name": "uint256",
                        "nodeType": "ElementaryTypeName",
                        "src": "7625:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 9520,
                  "initialValue": {
                    "argumentTypes": null,
                    "arguments": [],
                    "expression": {
                      "argumentTypes": [],
                      "expression": {
                        "argumentTypes": null,
                        "id": 9517,
                        "name": "cDai",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9206,
                        "src": "7638:4:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_contract$_cERC20_$9160",
                          "typeString": "contract cERC20"
                        }
                      },
                      "id": 9518,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "exchangeRateStored",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 9143,
                      "src": "7638:23:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_external_view$__$returns$_t_uint256_$",
                        "typeString": "function () view external returns (uint256)"
                      }
                    },
                    "id": 9519,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "7638:25:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "7625:38:29"
                },
                {
                  "assignments": [
                    9522
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 9522,
                      "name": "daiWorth",
                      "nodeType": "VariableDeclaration",
                      "scope": 9582,
                      "src": "7673:16:29",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 9521,
                        "name": "uint256",
                        "nodeType": "ElementaryTypeName",
                        "src": "7673:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 9525,
                  "initialValue": {
                    "argumentTypes": null,
                    "arguments": [],
                    "expression": {
                      "argumentTypes": [],
                      "id": 9523,
                      "name": "currentDAIWorth",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9506,
                      "src": "7692:15:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_internal_view$__$returns$_t_uint256_$",
                        "typeString": "function () view returns (uint256)"
                      }
                    },
                    "id": 9524,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "7692:17:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "7673:36:29"
                },
                {
                  "condition": {
                    "argumentTypes": null,
                    "commonType": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    },
                    "id": 9528,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftExpression": {
                      "argumentTypes": null,
                      "id": 9526,
                      "name": "daiWorth",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9522,
                      "src": "7723:8:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "BinaryOperation",
                    "operator": "<=",
                    "rightExpression": {
                      "argumentTypes": null,
                      "id": 9527,
                      "name": "totalStaked",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9213,
                      "src": "7735:11:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "7723:23:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "falseBody": null,
                  "id": 9535,
                  "nodeType": "IfStatement",
                  "src": "7719:70:29",
                  "trueBody": {
                    "id": 9534,
                    "nodeType": "Block",
                    "src": "7748:41:29",
                    "statements": [
                      {
                        "expression": {
                          "argumentTypes": null,
                          "components": [
                            {
                              "argumentTypes": null,
                              "hexValue": "30",
                              "id": 9529,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": true,
                              "kind": "number",
                              "lValueRequested": false,
                              "nodeType": "Literal",
                              "src": "7770:1:29",
                              "subdenomination": null,
                              "typeDescriptions": {
                                "typeIdentifier": "t_rational_0_by_1",
                                "typeString": "int_const 0"
                              },
                              "value": "0"
                            },
                            {
                              "argumentTypes": null,
                              "hexValue": "30",
                              "id": 9530,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": true,
                              "kind": "number",
                              "lValueRequested": false,
                              "nodeType": "Literal",
                              "src": "7773:1:29",
                              "subdenomination": null,
                              "typeDescriptions": {
                                "typeIdentifier": "t_rational_0_by_1",
                                "typeString": "int_const 0"
                              },
                              "value": "0"
                            },
                            {
                              "argumentTypes": null,
                              "hexValue": "30",
                              "id": 9531,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": true,
                              "kind": "number",
                              "lValueRequested": false,
                              "nodeType": "Literal",
                              "src": "7776:1:29",
                              "subdenomination": null,
                              "typeDescriptions": {
                                "typeIdentifier": "t_rational_0_by_1",
                                "typeString": "int_const 0"
                              },
                              "value": "0"
                            }
                          ],
                          "id": 9532,
                          "isConstant": false,
                          "isInlineArray": false,
                          "isLValue": false,
                          "isPure": true,
                          "lValueRequested": false,
                          "nodeType": "TupleExpression",
                          "src": "7769:9:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_tuple$_t_rational_0_by_1_$_t_rational_0_by_1_$_t_rational_0_by_1_$",
                            "typeString": "tuple(int_const 0,int_const 0,int_const 0)"
                          }
                        },
                        "functionReturnParameters": 9514,
                        "id": 9533,
                        "nodeType": "Return",
                        "src": "7762:16:29"
                      }
                    ]
                  }
                },
                {
                  "assignments": [
                    9537
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 9537,
                      "name": "daiGains",
                      "nodeType": "VariableDeclaration",
                      "scope": 9582,
                      "src": "7798:16:29",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 9536,
                        "name": "uint256",
                        "nodeType": "ElementaryTypeName",
                        "src": "7798:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 9542,
                  "initialValue": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "id": 9540,
                        "name": "totalStaked",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9213,
                        "src": "7830:11:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      ],
                      "expression": {
                        "argumentTypes": null,
                        "id": 9538,
                        "name": "daiWorth",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9522,
                        "src": "7817:8:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "id": 9539,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "sub",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 21263,
                      "src": "7817:12:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
                        "typeString": "function (uint256,uint256) pure returns (uint256)"
                      }
                    },
                    "id": 9541,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "7817:25:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "7798:44:29"
                },
                {
                  "assignments": [
                    9544
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 9544,
                      "name": "cdaiGains",
                      "nodeType": "VariableDeclaration",
                      "scope": 9582,
                      "src": "7984:17:29",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 9543,
                        "name": "uint256",
                        "nodeType": "ElementaryTypeName",
                        "src": "7984:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 9552,
                  "initialValue": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "hexValue": "31653130",
                            "id": 9548,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": true,
                            "kind": "number",
                            "lValueRequested": false,
                            "nodeType": "Literal",
                            "src": "8022:4:29",
                            "subdenomination": null,
                            "typeDescriptions": {
                              "typeIdentifier": "t_rational_10000000000_by_1",
                              "typeString": "int_const 10000000000"
                            },
                            "value": "1e10"
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_rational_10000000000_by_1",
                              "typeString": "int_const 10000000000"
                            }
                          ],
                          "expression": {
                            "argumentTypes": null,
                            "id": 9546,
                            "name": "daiGains",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 9537,
                            "src": "8009:8:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          },
                          "id": 9547,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "memberName": "mul",
                          "nodeType": "MemberAccess",
                          "referencedDeclaration": 21215,
                          "src": "8009:12:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
                            "typeString": "function (uint256,uint256) pure returns (uint256)"
                          }
                        },
                        "id": 9549,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "functionCall",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "8009:18:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 9550,
                        "name": "er",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9516,
                        "src": "8029:2:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        },
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      ],
                      "id": 9545,
                      "name": "rdiv",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 247,
                      "src": "8004:4:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$",
                        "typeString": "function (uint256,uint256) pure returns (uint256)"
                      }
                    },
                    "id": 9551,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "8004:28:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "7984:48:29"
                },
                {
                  "assignments": [
                    9554
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 9554,
                      "name": "precisionLossCDaiRay",
                      "nodeType": "VariableDeclaration",
                      "scope": 9582,
                      "src": "8159:28:29",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 9553,
                        "name": "uint256",
                        "nodeType": "ElementaryTypeName",
                        "src": "8159:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 9559,
                  "initialValue": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "hexValue": "31653139",
                        "id": 9557,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "number",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "8204:4:29",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_rational_10000000000000000000_by_1",
                          "typeString": "int_const 10000000000000000000"
                        },
                        "value": "1e19"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_rational_10000000000000000000_by_1",
                          "typeString": "int_const 10000000000000000000"
                        }
                      ],
                      "expression": {
                        "argumentTypes": null,
                        "id": 9555,
                        "name": "cdaiGains",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9544,
                        "src": "8190:9:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "id": 9556,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "mod",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 21307,
                      "src": "8190:13:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
                        "typeString": "function (uint256,uint256) pure returns (uint256)"
                      }
                    },
                    "id": 9558,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "8190:19:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "8159:50:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 9565,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 9560,
                      "name": "cdaiGains",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9544,
                      "src": "8255:9:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "hexValue": "31653139",
                          "id": 9563,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "kind": "number",
                          "lValueRequested": false,
                          "nodeType": "Literal",
                          "src": "8281:4:29",
                          "subdenomination": null,
                          "typeDescriptions": {
                            "typeIdentifier": "t_rational_10000000000000000000_by_1",
                            "typeString": "int_const 10000000000000000000"
                          },
                          "value": "1e19"
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_rational_10000000000000000000_by_1",
                            "typeString": "int_const 10000000000000000000"
                          }
                        ],
                        "expression": {
                          "argumentTypes": null,
                          "id": 9561,
                          "name": "cdaiGains",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9544,
                          "src": "8267:9:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "id": 9562,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "div",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 21239,
                        "src": "8267:13:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
                          "typeString": "function (uint256,uint256) pure returns (uint256)"
                        }
                      },
                      "id": 9564,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "functionCall",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "8267:19:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "8255:31:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 9566,
                  "nodeType": "ExpressionStatement",
                  "src": "8255:31:29"
                },
                {
                  "assignments": [
                    9568
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 9568,
                      "name": "precisionLossDai",
                      "nodeType": "VariableDeclaration",
                      "scope": 9582,
                      "src": "8355:24:29",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 9567,
                        "name": "uint256",
                        "nodeType": "ElementaryTypeName",
                        "src": "8355:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 9576,
                  "initialValue": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "hexValue": "31653130",
                        "id": 9574,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "number",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "8417:4:29",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_rational_10000000000_by_1",
                          "typeString": "int_const 10000000000"
                        },
                        "value": "1e10"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_rational_10000000000_by_1",
                          "typeString": "int_const 10000000000"
                        }
                      ],
                      "expression": {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "id": 9570,
                            "name": "precisionLossCDaiRay",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 9554,
                            "src": "8387:20:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          },
                          {
                            "argumentTypes": null,
                            "id": 9571,
                            "name": "er",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 9516,
                            "src": "8409:2:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            },
                            {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          ],
                          "id": 9569,
                          "name": "rmul",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 199,
                          "src": "8382:4:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$",
                            "typeString": "function (uint256,uint256) pure returns (uint256)"
                          }
                        },
                        "id": 9572,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "functionCall",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "8382:30:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "id": 9573,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "div",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 21239,
                      "src": "8382:34:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
                        "typeString": "function (uint256,uint256) pure returns (uint256)"
                      }
                    },
                    "id": 9575,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "8382:40:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "8355:67:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "components": [
                      {
                        "argumentTypes": null,
                        "id": 9577,
                        "name": "cdaiGains",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9544,
                        "src": "8440:9:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 9578,
                        "name": "daiGains",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9537,
                        "src": "8451:8:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 9579,
                        "name": "precisionLossDai",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9568,
                        "src": "8461:16:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      }
                    ],
                    "id": 9580,
                    "isConstant": false,
                    "isInlineArray": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "nodeType": "TupleExpression",
                    "src": "8439:39:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$",
                      "typeString": "tuple(uint256,uint256,uint256)"
                    }
                  },
                  "functionReturnParameters": 9514,
                  "id": 9581,
                  "nodeType": "Return",
                  "src": "8432:46:29"
                }
              ]
            },
            "documentation": "@dev Calculates the current interest that was gained.\n@return (uint256, uint256, uint256) The interest in cDAI, the interest in DAI,\nthe amount which is not covered by precision of DAI",
            "id": 9583,
            "implemented": true,
            "kind": "function",
            "modifiers": [],
            "name": "currentUBIInterest",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9507,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "7490:2:29"
            },
            "returnParameters": {
              "id": 9514,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9509,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 9583,
                  "src": "7551:7:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9508,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "7551:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9511,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 9583,
                  "src": "7572:7:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9510,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "7572:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9513,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 9583,
                  "src": "7593:7:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9512,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "7593:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "7537:73:29"
            },
            "scope": 9740,
            "src": "7463:1022:29",
            "stateMutability": "view",
            "superFunction": null,
            "visibility": "public"
          },
          {
            "body": {
              "id": 9656,
              "nodeType": "Block",
              "src": "9087:716:29",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "commonType": {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        },
                        "id": 9603,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "leftExpression": {
                          "argumentTypes": null,
                          "id": 9599,
                          "name": "_recipient",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9585,
                          "src": "9173:10:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_address",
                            "typeString": "address"
                          }
                        },
                        "nodeType": "BinaryOperation",
                        "operator": "!=",
                        "rightExpression": {
                          "argumentTypes": null,
                          "arguments": [
                            {
                              "argumentTypes": null,
                              "id": 9601,
                              "name": "this",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 22327,
                              "src": "9195:4:29",
                              "typeDescriptions": {
                                "typeIdentifier": "t_contract$_SimpleDAIStaking_$9740",
                                "typeString": "contract SimpleDAIStaking"
                              }
                            }
                          ],
                          "expression": {
                            "argumentTypes": [
                              {
                                "typeIdentifier": "t_contract$_SimpleDAIStaking_$9740",
                                "typeString": "contract SimpleDAIStaking"
                              }
                            ],
                            "id": 9600,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": true,
                            "lValueRequested": false,
                            "nodeType": "ElementaryTypeNameExpression",
                            "src": "9187:7:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_type$_t_address_$",
                              "typeString": "type(address)"
                            },
                            "typeName": "address"
                          },
                          "id": 9602,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "kind": "typeConversion",
                          "lValueRequested": false,
                          "names": [],
                          "nodeType": "FunctionCall",
                          "src": "9187:13:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_address",
                            "typeString": "address"
                          }
                        },
                        "src": "9173:27:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "hexValue": "526563697069656e742063616e6e6f7420626520746865207374616b696e6720636f6e7472616374",
                        "id": 9604,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "9202:42:29",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_b186bec0df383c90e23d5b956c4da2f18dd93ac86eb077c5c0e428a763cbd6fa",
                          "typeString": "literal_string \"Recipient cannot be the staking contract\""
                        },
                        "value": "Recipient cannot be the staking contract"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        {
                          "typeIdentifier": "t_stringliteral_b186bec0df383c90e23d5b956c4da2f18dd93ac86eb077c5c0e428a763cbd6fa",
                          "typeString": "literal_string \"Recipient cannot be the staking contract\""
                        }
                      ],
                      "id": 9598,
                      "name": "require",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [
                        22174,
                        22175
                      ],
                      "referencedDeclaration": 22175,
                      "src": "9165:7:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                        "typeString": "function (bool,string memory) pure"
                      }
                    },
                    "id": 9605,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "9165:80:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 9606,
                  "nodeType": "ExpressionStatement",
                  "src": "9165:80:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "arguments": [],
                        "expression": {
                          "argumentTypes": [],
                          "id": 9608,
                          "name": "canCollect",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9671,
                          "src": "9264:10:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_function_internal_view$__$returns$_t_bool_$",
                            "typeString": "function () view returns (bool)"
                          }
                        },
                        "id": 9609,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "functionCall",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "9264:12:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "hexValue": "4e65656420746f207761697420666f7220746865206e65787420696e74657276616c",
                        "id": 9610,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "9278:36:29",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_b2926b938aae9e3d3391834a8a3f967955ec6bac9d9b401e186c29404478d446",
                          "typeString": "literal_string \"Need to wait for the next interval\""
                        },
                        "value": "Need to wait for the next interval"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        {
                          "typeIdentifier": "t_stringliteral_b2926b938aae9e3d3391834a8a3f967955ec6bac9d9b401e186c29404478d446",
                          "typeString": "literal_string \"Need to wait for the next interval\""
                        }
                      ],
                      "id": 9607,
                      "name": "require",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [
                        22174,
                        22175
                      ],
                      "referencedDeclaration": 22175,
                      "src": "9256:7:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                        "typeString": "function (bool,string memory) pure"
                      }
                    },
                    "id": 9611,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "9256:59:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 9612,
                  "nodeType": "ExpressionStatement",
                  "src": "9256:59:29"
                },
                {
                  "assignments": [
                    9614,
                    9616,
                    9618
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 9614,
                      "name": "cdaiGains",
                      "nodeType": "VariableDeclaration",
                      "scope": 9656,
                      "src": "9340:17:29",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 9613,
                        "name": "uint256",
                        "nodeType": "ElementaryTypeName",
                        "src": "9340:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    },
                    {
                      "constant": false,
                      "id": 9616,
                      "name": "daiGains",
                      "nodeType": "VariableDeclaration",
                      "scope": 9656,
                      "src": "9371:16:29",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 9615,
                        "name": "uint256",
                        "nodeType": "ElementaryTypeName",
                        "src": "9371:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    },
                    {
                      "constant": false,
                      "id": 9618,
                      "name": "precisionLossDai",
                      "nodeType": "VariableDeclaration",
                      "scope": 9656,
                      "src": "9401:24:29",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 9617,
                        "name": "uint256",
                        "nodeType": "ElementaryTypeName",
                        "src": "9401:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 9621,
                  "initialValue": {
                    "argumentTypes": null,
                    "arguments": [],
                    "expression": {
                      "argumentTypes": [],
                      "id": 9619,
                      "name": "currentUBIInterest",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9583,
                      "src": "9438:18:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_internal_view$__$returns$_t_uint256_$_t_uint256_$_t_uint256_$",
                        "typeString": "function () view returns (uint256,uint256,uint256)"
                      }
                    },
                    "id": 9620,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "9438:20:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$",
                      "typeString": "tuple(uint256,uint256,uint256)"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "9326:132:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 9628,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 9622,
                      "name": "lastUBICollection",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9210,
                      "src": "9468:17:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 9626,
                          "name": "blockInterval",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9208,
                          "src": "9505:13:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        ],
                        "expression": {
                          "argumentTypes": null,
                          "expression": {
                            "argumentTypes": null,
                            "id": 9623,
                            "name": "block",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 22161,
                            "src": "9488:5:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_magic_block",
                              "typeString": "block"
                            }
                          },
                          "id": 9624,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "memberName": "number",
                          "nodeType": "MemberAccess",
                          "referencedDeclaration": null,
                          "src": "9488:12:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "id": 9625,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "div",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 21239,
                        "src": "9488:16:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
                          "typeString": "function (uint256,uint256) pure returns (uint256)"
                        }
                      },
                      "id": 9627,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "functionCall",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "9488:31:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "9468:51:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 9629,
                  "nodeType": "ExpressionStatement",
                  "src": "9468:51:29"
                },
                {
                  "condition": {
                    "argumentTypes": null,
                    "commonType": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    },
                    "id": 9632,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftExpression": {
                      "argumentTypes": null,
                      "id": 9630,
                      "name": "cdaiGains",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9614,
                      "src": "9533:9:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "BinaryOperation",
                    "operator": ">",
                    "rightExpression": {
                      "argumentTypes": null,
                      "hexValue": "30",
                      "id": 9631,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": true,
                      "kind": "number",
                      "lValueRequested": false,
                      "nodeType": "Literal",
                      "src": "9545:1:29",
                      "subdenomination": null,
                      "typeDescriptions": {
                        "typeIdentifier": "t_rational_0_by_1",
                        "typeString": "int_const 0"
                      },
                      "value": "0"
                    },
                    "src": "9533:13:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "falseBody": null,
                  "id": 9642,
                  "nodeType": "IfStatement",
                  "src": "9529:103:29",
                  "trueBody": {
                    "expression": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "arguments": [
                            {
                              "argumentTypes": null,
                              "id": 9636,
                              "name": "_recipient",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 9585,
                              "src": "9582:10:29",
                              "typeDescriptions": {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "id": 9637,
                              "name": "cdaiGains",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 9614,
                              "src": "9594:9:29",
                              "typeDescriptions": {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              }
                            }
                          ],
                          "expression": {
                            "argumentTypes": [
                              {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              },
                              {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              }
                            ],
                            "expression": {
                              "argumentTypes": null,
                              "id": 9634,
                              "name": "cDai",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 9206,
                              "src": "9568:4:29",
                              "typeDescriptions": {
                                "typeIdentifier": "t_contract$_cERC20_$9160",
                                "typeString": "contract cERC20"
                              }
                            },
                            "id": 9635,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": false,
                            "lValueRequested": false,
                            "memberName": "transfer",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": 9159,
                            "src": "9568:13:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$",
                              "typeString": "function (address,uint256) external returns (bool)"
                            }
                          },
                          "id": 9638,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "kind": "functionCall",
                          "lValueRequested": false,
                          "names": [],
                          "nodeType": "FunctionCall",
                          "src": "9568:36:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_bool",
                            "typeString": "bool"
                          }
                        },
                        {
                          "argumentTypes": null,
                          "hexValue": "636f6c6c656374207472616e73666572206661696c6564",
                          "id": 9639,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "kind": "string",
                          "lValueRequested": false,
                          "nodeType": "Literal",
                          "src": "9606:25:29",
                          "subdenomination": null,
                          "typeDescriptions": {
                            "typeIdentifier": "t_stringliteral_c955f53632207d8104a997da6e051a24feef1c53c0972ac3af4bdda83f5d190e",
                            "typeString": "literal_string \"collect transfer failed\""
                          },
                          "value": "collect transfer failed"
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_bool",
                            "typeString": "bool"
                          },
                          {
                            "typeIdentifier": "t_stringliteral_c955f53632207d8104a997da6e051a24feef1c53c0972ac3af4bdda83f5d190e",
                            "typeString": "literal_string \"collect transfer failed\""
                          }
                        ],
                        "id": 9633,
                        "name": "require",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [
                          22174,
                          22175
                        ],
                        "referencedDeclaration": 22175,
                        "src": "9560:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                          "typeString": "function (bool,string memory) pure"
                        }
                      },
                      "id": 9640,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "functionCall",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "9560:72:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_tuple$__$",
                        "typeString": "tuple()"
                      }
                    },
                    "id": 9641,
                    "nodeType": "ExpressionStatement",
                    "src": "9560:72:29"
                  }
                },
                {
                  "eventCall": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "id": 9644,
                        "name": "_recipient",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9585,
                        "src": "9665:10:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 9645,
                        "name": "cdaiGains",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9614,
                        "src": "9677:9:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 9646,
                        "name": "daiGains",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9616,
                        "src": "9688:8:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 9647,
                        "name": "precisionLossDai",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9618,
                        "src": "9698:16:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        },
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        },
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        },
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      ],
                      "id": 9643,
                      "name": "InterestCollected",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9202,
                      "src": "9647:17:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$_t_uint256_$returns$__$",
                        "typeString": "function (address,uint256,uint256,uint256)"
                      }
                    },
                    "id": 9648,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "9647:68:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 9649,
                  "nodeType": "EmitStatement",
                  "src": "9642:73:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "components": [
                      {
                        "argumentTypes": null,
                        "id": 9650,
                        "name": "cdaiGains",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9614,
                        "src": "9733:9:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 9651,
                        "name": "daiGains",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9616,
                        "src": "9744:8:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 9652,
                        "name": "precisionLossDai",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9618,
                        "src": "9754:16:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 9653,
                        "name": "avgInterestDonatedRatio",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9216,
                        "src": "9772:23:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint32",
                          "typeString": "uint32"
                        }
                      }
                    ],
                    "id": 9654,
                    "isConstant": false,
                    "isInlineArray": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "nodeType": "TupleExpression",
                    "src": "9732:64:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint32_$",
                      "typeString": "tuple(uint256,uint256,uint256,uint32)"
                    }
                  },
                  "functionReturnParameters": 9597,
                  "id": 9655,
                  "nodeType": "Return",
                  "src": "9725:71:29"
                }
              ]
            },
            "documentation": "@dev Collects gained interest by fundmanager. Can be collected only once\nin an interval which is defined above.\n@param _recipient The recipient of cDAI gains\n@return (uint256, uint256, uint256, uint32) The interest in cDAI, the interest in DAI,\nthe amount which is not covered by precision of DAI, how much of the generated interest is donated",
            "id": 9657,
            "implemented": true,
            "kind": "function",
            "modifiers": [
              {
                "arguments": null,
                "id": 9588,
                "modifierName": {
                  "argumentTypes": null,
                  "id": 9587,
                  "name": "onlyFundManager",
                  "nodeType": "Identifier",
                  "overloadedDeclarations": [],
                  "referencedDeclaration": 9230,
                  "src": "8957:15:29",
                  "typeDescriptions": {
                    "typeIdentifier": "t_modifier$__$",
                    "typeString": "modifier ()"
                  }
                },
                "nodeType": "ModifierInvocation",
                "src": "8957:15:29"
              }
            ],
            "name": "collectUBIInterest",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9586,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9585,
                  "name": "_recipient",
                  "nodeType": "VariableDeclaration",
                  "scope": 9657,
                  "src": "8914:18:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 9584,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "8914:7:29",
                    "stateMutability": "nonpayable",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "8913:20:29"
            },
            "returnParameters": {
              "id": 9597,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9590,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 9657,
                  "src": "9003:7:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9589,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "9003:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9592,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 9657,
                  "src": "9024:7:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9591,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "9024:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9594,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 9657,
                  "src": "9045:7:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 9593,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "9045:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 9596,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 9657,
                  "src": "9066:6:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint32",
                    "typeString": "uint32"
                  },
                  "typeName": {
                    "id": 9595,
                    "name": "uint32",
                    "nodeType": "ElementaryTypeName",
                    "src": "9066:6:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint32",
                      "typeString": "uint32"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "8989:93:29"
            },
            "scope": 9740,
            "src": "8886:917:29",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "public"
          },
          {
            "body": {
              "id": 9670,
              "nodeType": "Block",
              "src": "10084:75:29",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "commonType": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    },
                    "id": 9668,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftExpression": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 9665,
                          "name": "blockInterval",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9208,
                          "src": "10118:13:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        ],
                        "expression": {
                          "argumentTypes": null,
                          "expression": {
                            "argumentTypes": null,
                            "id": 9662,
                            "name": "block",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 22161,
                            "src": "10101:5:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_magic_block",
                              "typeString": "block"
                            }
                          },
                          "id": 9663,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "memberName": "number",
                          "nodeType": "MemberAccess",
                          "referencedDeclaration": null,
                          "src": "10101:12:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "id": 9664,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "div",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 21239,
                        "src": "10101:16:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
                          "typeString": "function (uint256,uint256) pure returns (uint256)"
                        }
                      },
                      "id": 9666,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "functionCall",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "10101:31:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "BinaryOperation",
                    "operator": ">",
                    "rightExpression": {
                      "argumentTypes": null,
                      "id": 9667,
                      "name": "lastUBICollection",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 9210,
                      "src": "10135:17:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "10101:51:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "functionReturnParameters": 9661,
                  "id": 9669,
                  "nodeType": "Return",
                  "src": "10094:58:29"
                }
              ]
            },
            "documentation": "@dev Checks if enough blocks have passed so it would be possible to\nexecute `collectUBIInterest` according to the length of `blockInterval`\n@return (bool) True if enough blocks have passed",
            "id": 9671,
            "implemented": true,
            "kind": "function",
            "modifiers": [],
            "name": "canCollect",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9658,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "10054:2:29"
            },
            "returnParameters": {
              "id": 9661,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9660,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 9671,
                  "src": "10078:4:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_bool",
                    "typeString": "bool"
                  },
                  "typeName": {
                    "id": 9659,
                    "name": "bool",
                    "nodeType": "ElementaryTypeName",
                    "src": "10078:4:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "10077:6:29"
            },
            "scope": 9740,
            "src": "10035:124:29",
            "stateMutability": "view",
            "superFunction": null,
            "visibility": "public"
          },
          {
            "body": {
              "id": 9679,
              "nodeType": "Block",
              "src": "10350:28:29",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [],
                    "expression": {
                      "argumentTypes": [],
                      "id": 9676,
                      "name": "addRights",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 1203,
                      "src": "10360:9:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_internal_nonpayable$__$returns$__$",
                        "typeString": "function ()"
                      }
                    },
                    "id": 9677,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "10360:11:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 9678,
                  "nodeType": "ExpressionStatement",
                  "src": "10360:11:29"
                }
              ]
            },
            "documentation": "@dev Start function. Adds this contract to identity as a feeless scheme.\nCan only be called if scheme is registered",
            "id": 9680,
            "implemented": true,
            "kind": "function",
            "modifiers": [
              {
                "arguments": null,
                "id": 9674,
                "modifierName": {
                  "argumentTypes": null,
                  "id": 9673,
                  "name": "onlyRegistered",
                  "nodeType": "Identifier",
                  "overloadedDeclarations": [],
                  "referencedDeclaration": 1335,
                  "src": "10335:14:29",
                  "typeDescriptions": {
                    "typeIdentifier": "t_modifier$__$",
                    "typeString": "modifier ()"
                  }
                },
                "nodeType": "ModifierInvocation",
                "src": "10335:14:29"
              }
            ],
            "name": "start",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9672,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "10325:2:29"
            },
            "returnParameters": {
              "id": 9675,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "10350:0:29"
            },
            "scope": 9740,
            "src": "10311:67:29",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "public"
          },
          {
            "body": {
              "id": 9691,
              "nodeType": "Block",
              "src": "10643:48:29",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [],
                    "expression": {
                      "argumentTypes": [],
                      "id": 9685,
                      "name": "pause",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 21093,
                      "src": "10653:5:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_internal_nonpayable$__$returns$__$",
                        "typeString": "function ()"
                      }
                    },
                    "id": 9686,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "10653:7:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 9687,
                  "nodeType": "ExpressionStatement",
                  "src": "10653:7:29"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [],
                    "expression": {
                      "argumentTypes": [],
                      "id": 9688,
                      "name": "removeRights",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 1226,
                      "src": "10670:12:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_internal_nonpayable$__$returns$__$",
                        "typeString": "function ()"
                      }
                    },
                    "id": 9689,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "10670:14:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 9690,
                  "nodeType": "ExpressionStatement",
                  "src": "10670:14:29"
                }
              ]
            },
            "documentation": "@dev making the contract inactive\nNOTICE: this could theoretically result in future interest earned in cdai to remain locked\nbut we dont expect any other stakers but us in SimpleDAIStaking",
            "id": 9692,
            "implemented": true,
            "kind": "function",
            "modifiers": [
              {
                "arguments": null,
                "id": 9683,
                "modifierName": {
                  "argumentTypes": null,
                  "id": 9682,
                  "name": "onlyAvatar",
                  "nodeType": "Identifier",
                  "overloadedDeclarations": [],
                  "referencedDeclaration": 1325,
                  "src": "10632:10:29",
                  "typeDescriptions": {
                    "typeIdentifier": "t_modifier$__$",
                    "typeString": "modifier ()"
                  }
                },
                "nodeType": "ModifierInvocation",
                "src": "10632:10:29"
              }
            ],
            "name": "end",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9681,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "10622:2:29"
            },
            "returnParameters": {
              "id": 9684,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "10643:0:29"
            },
            "scope": 9740,
            "src": "10610:81:29",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "public"
          },
          {
            "body": {
              "id": 9738,
              "nodeType": "Block",
              "src": "10883:457:29",
              "statements": [
                {
                  "assignments": [
                    9700
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 9700,
                      "name": "toWithdraw",
                      "nodeType": "VariableDeclaration",
                      "scope": 9738,
                      "src": "10893:18:29",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 9699,
                        "name": "uint256",
                        "nodeType": "ElementaryTypeName",
                        "src": "10893:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 9707,
                  "initialValue": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "id": 9704,
                            "name": "this",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 22327,
                            "src": "10939:4:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_contract$_SimpleDAIStaking_$9740",
                              "typeString": "contract SimpleDAIStaking"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_contract$_SimpleDAIStaking_$9740",
                              "typeString": "contract SimpleDAIStaking"
                            }
                          ],
                          "id": 9703,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "lValueRequested": false,
                          "nodeType": "ElementaryTypeNameExpression",
                          "src": "10931:7:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_address_$",
                            "typeString": "type(address)"
                          },
                          "typeName": "address"
                        },
                        "id": 9705,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "typeConversion",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "10931:13:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      ],
                      "expression": {
                        "argumentTypes": null,
                        "id": 9701,
                        "name": "_token",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9694,
                        "src": "10914:6:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_contract$_ERC20_$21849",
                          "typeString": "contract ERC20"
                        }
                      },
                      "id": 9702,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "balanceOf",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 21458,
                      "src": "10914:16:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$",
                        "typeString": "function (address) view external returns (uint256)"
                      }
                    },
                    "id": 9706,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "10914:31:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "10893:52:29"
                },
                {
                  "condition": {
                    "argumentTypes": null,
                    "commonType": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    },
                    "id": 9714,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftExpression": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 9709,
                          "name": "_token",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9694,
                          "src": "11053:6:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_contract$_ERC20_$21849",
                            "typeString": "contract ERC20"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_contract$_ERC20_$21849",
                            "typeString": "contract ERC20"
                          }
                        ],
                        "id": 9708,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "lValueRequested": false,
                        "nodeType": "ElementaryTypeNameExpression",
                        "src": "11045:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_type$_t_address_$",
                          "typeString": "type(address)"
                        },
                        "typeName": "address"
                      },
                      "id": 9710,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "typeConversion",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "11045:15:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "nodeType": "BinaryOperation",
                    "operator": "==",
                    "rightExpression": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 9712,
                          "name": "cDai",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 9206,
                          "src": "11072:4:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_contract$_cERC20_$9160",
                            "typeString": "contract cERC20"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_contract$_cERC20_$9160",
                            "typeString": "contract cERC20"
                          }
                        ],
                        "id": 9711,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "lValueRequested": false,
                        "nodeType": "ElementaryTypeNameExpression",
                        "src": "11064:7:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_type$_t_address_$",
                          "typeString": "type(address)"
                        },
                        "typeName": "address"
                      },
                      "id": 9713,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "typeConversion",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "11064:13:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "src": "11045:32:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "falseBody": null,
                  "id": 9726,
                  "nodeType": "IfStatement",
                  "src": "11041:203:29",
                  "trueBody": {
                    "id": 9725,
                    "nodeType": "Block",
                    "src": "11079:165:29",
                    "statements": [
                      {
                        "expression": {
                          "argumentTypes": null,
                          "arguments": [
                            {
                              "argumentTypes": null,
                              "commonType": {
                                "typeIdentifier": "t_bool",
                                "typeString": "bool"
                              },
                              "id": 9721,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "lValueRequested": false,
                              "leftExpression": {
                                "argumentTypes": null,
                                "commonType": {
                                  "typeIdentifier": "t_uint256",
                                  "typeString": "uint256"
                                },
                                "id": 9718,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": false,
                                "lValueRequested": false,
                                "leftExpression": {
                                  "argumentTypes": null,
                                  "id": 9716,
                                  "name": "totalStaked",
                                  "nodeType": "Identifier",
                                  "overloadedDeclarations": [],
                                  "referencedDeclaration": 9213,
                                  "src": "11118:11:29",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                },
                                "nodeType": "BinaryOperation",
                                "operator": "==",
                                "rightExpression": {
                                  "argumentTypes": null,
                                  "hexValue": "30",
                                  "id": 9717,
                                  "isConstant": false,
                                  "isLValue": false,
                                  "isPure": true,
                                  "kind": "number",
                                  "lValueRequested": false,
                                  "nodeType": "Literal",
                                  "src": "11133:1:29",
                                  "subdenomination": null,
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_rational_0_by_1",
                                    "typeString": "int_const 0"
                                  },
                                  "value": "0"
                                },
                                "src": "11118:16:29",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_bool",
                                  "typeString": "bool"
                                }
                              },
                              "nodeType": "BinaryOperation",
                              "operator": "&&",
                              "rightExpression": {
                                "argumentTypes": null,
                                "arguments": [],
                                "expression": {
                                  "argumentTypes": [],
                                  "id": 9719,
                                  "name": "paused",
                                  "nodeType": "Identifier",
                                  "overloadedDeclarations": [],
                                  "referencedDeclaration": 21059,
                                  "src": "11138:6:29",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_function_internal_view$__$returns$_t_bool_$",
                                    "typeString": "function () view returns (bool)"
                                  }
                                },
                                "id": 9720,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": false,
                                "kind": "functionCall",
                                "lValueRequested": false,
                                "names": [],
                                "nodeType": "FunctionCall",
                                "src": "11138:8:29",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_bool",
                                  "typeString": "bool"
                                }
                              },
                              "src": "11118:28:29",
                              "typeDescriptions": {
                                "typeIdentifier": "t_bool",
                                "typeString": "bool"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "hexValue": "63616e207265636f7665722063446169206f6e6c79207768656e207374616b65732068617665206265656e2077697468647261776e",
                              "id": 9722,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": true,
                              "kind": "string",
                              "lValueRequested": false,
                              "nodeType": "Literal",
                              "src": "11164:55:29",
                              "subdenomination": null,
                              "typeDescriptions": {
                                "typeIdentifier": "t_stringliteral_79607305dd51ed20c601fc68ead0738527c2757f2ece05378363c3502b2aaa0c",
                                "typeString": "literal_string \"can recover cDai only when stakes have been withdrawn\""
                              },
                              "value": "can recover cDai only when stakes have been withdrawn"
                            }
                          ],
                          "expression": {
                            "argumentTypes": [
                              {
                                "typeIdentifier": "t_bool",
                                "typeString": "bool"
                              },
                              {
                                "typeIdentifier": "t_stringliteral_79607305dd51ed20c601fc68ead0738527c2757f2ece05378363c3502b2aaa0c",
                                "typeString": "literal_string \"can recover cDai only when stakes have been withdrawn\""
                              }
                            ],
                            "id": 9715,
                            "name": "require",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [
                              22174,
                              22175
                            ],
                            "referencedDeclaration": 22175,
                            "src": "11093:7:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                              "typeString": "function (bool,string memory) pure"
                            }
                          },
                          "id": 9723,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "kind": "functionCall",
                          "lValueRequested": false,
                          "names": [],
                          "nodeType": "FunctionCall",
                          "src": "11093:140:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_tuple$__$",
                            "typeString": "tuple()"
                          }
                        },
                        "id": 9724,
                        "nodeType": "ExpressionStatement",
                        "src": "11093:140:29"
                      }
                    ]
                  }
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "arguments": [
                              {
                                "argumentTypes": null,
                                "id": 9731,
                                "name": "avatar",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 1281,
                                "src": "11285:6:29",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_contract$_Avatar_$12705",
                                  "typeString": "contract Avatar"
                                }
                              }
                            ],
                            "expression": {
                              "argumentTypes": [
                                {
                                  "typeIdentifier": "t_contract$_Avatar_$12705",
                                  "typeString": "contract Avatar"
                                }
                              ],
                              "id": 9730,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": true,
                              "lValueRequested": false,
                              "nodeType": "ElementaryTypeNameExpression",
                              "src": "11277:7:29",
                              "typeDescriptions": {
                                "typeIdentifier": "t_type$_t_address_$",
                                "typeString": "type(address)"
                              },
                              "typeName": "address"
                            },
                            "id": 9732,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": false,
                            "kind": "typeConversion",
                            "lValueRequested": false,
                            "names": [],
                            "nodeType": "FunctionCall",
                            "src": "11277:15:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_address_payable",
                              "typeString": "address payable"
                            }
                          },
                          {
                            "argumentTypes": null,
                            "id": 9733,
                            "name": "toWithdraw",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 9700,
                            "src": "11294:10:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_address_payable",
                              "typeString": "address payable"
                            },
                            {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          ],
                          "expression": {
                            "argumentTypes": null,
                            "id": 9728,
                            "name": "_token",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 9694,
                            "src": "11261:6:29",
                            "typeDescriptions": {
                              "typeIdentifier": "t_contract$_ERC20_$21849",
                              "typeString": "contract ERC20"
                            }
                          },
                          "id": 9729,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "memberName": "transfer",
                          "nodeType": "MemberAccess",
                          "referencedDeclaration": 21493,
                          "src": "11261:15:29",
                          "typeDescriptions": {
                            "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$",
                            "typeString": "function (address,uint256) external returns (bool)"
                          }
                        },
                        "id": 9734,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "functionCall",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "11261:44:29",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "hexValue": "7265636f766572207472616e73666572206661696c6564",
                        "id": 9735,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "11307:25:29",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_41a03013a5674cc54e9badb52c47e3c4670bc54fa0765e5276b5118633f8aeb3",
                          "typeString": "literal_string \"recover transfer failed\""
                        },
                        "value": "recover transfer failed"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        {
                          "typeIdentifier": "t_stringliteral_41a03013a5674cc54e9badb52c47e3c4670bc54fa0765e5276b5118633f8aeb3",
                          "typeString": "literal_string \"recover transfer failed\""
                        }
                      ],
                      "id": 9727,
                      "name": "require",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [
                        22174,
                        22175
                      ],
                      "referencedDeclaration": 22175,
                      "src": "11253:7:29",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                        "typeString": "function (bool,string memory) pure"
                      }
                    },
                    "id": 9736,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "11253:80:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 9737,
                  "nodeType": "ExpressionStatement",
                  "src": "11253:80:29"
                }
              ]
            },
            "documentation": "@dev method to recover any stuck erc20 tokens (ie  compound COMP)\n@param _token the ERC20 token to recover",
            "id": 9739,
            "implemented": true,
            "kind": "function",
            "modifiers": [
              {
                "arguments": null,
                "id": 9697,
                "modifierName": {
                  "argumentTypes": null,
                  "id": 9696,
                  "name": "onlyAvatar",
                  "nodeType": "Identifier",
                  "overloadedDeclarations": [],
                  "referencedDeclaration": 1325,
                  "src": "10872:10:29",
                  "typeDescriptions": {
                    "typeIdentifier": "t_modifier$__$",
                    "typeString": "modifier ()"
                  }
                },
                "nodeType": "ModifierInvocation",
                "src": "10872:10:29"
              }
            ],
            "name": "recover",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 9695,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 9694,
                  "name": "_token",
                  "nodeType": "VariableDeclaration",
                  "scope": 9739,
                  "src": "10851:12:29",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_contract$_ERC20_$21849",
                    "typeString": "contract ERC20"
                  },
                  "typeName": {
                    "contractScope": null,
                    "id": 9693,
                    "name": "ERC20",
                    "nodeType": "UserDefinedTypeName",
                    "referencedDeclaration": 21849,
                    "src": "10851:5:29",
                    "typeDescriptions": {
                      "typeIdentifier": "t_contract$_ERC20_$21849",
                      "typeString": "contract ERC20"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "10850:14:29"
            },
            "returnParameters": {
              "id": 9698,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "10883:0:29"
            },
            "scope": 9740,
            "src": "10834:506:29",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "public"
          }
        ],
        "scope": 9741,
        "src": "1073:10269:29"
      }
    ],
    "src": "0:11343:29"
  },
  "compiler": {
    "name": "solc",
    "version": "0.5.16+commit.9c3226ce.Emscripten.clang"
  },
  "networks": {},
  "schemaVersion": "3.2.2",
  "updatedAt": "2021-08-23T07:33:52.323Z",
  "devdoc": {
    "methods": {
      "canCollect()": {
        "details": "Checks if enough blocks have passed so it would be possible to execute `collectUBIInterest` according to the length of `blockInterval`",
        "return": "(bool) True if enough blocks have passed"
      },
      "collectUBIInterest(address)": {
        "details": "Collects gained interest by fundmanager. Can be collected only once in an interval which is defined above.",
        "params": {
          "_recipient": "The recipient of cDAI gains"
        },
        "return": "(uint256, uint256, uint256, uint32) The interest in cDAI, the interest in DAI, the amount which is not covered by precision of DAI, how much of the generated interest is donated"
      },
      "constructor": {
        "details": "Constructor",
        "params": {
          "_avatar": "The avatar of the DAO",
          "_blockInterval": "How many blocks should be passed before the next execution of `collectUBIInterest`",
          "_cDai": "The address of cDAI",
          "_dai": "The address of DAI",
          "_fundManager": "The address of the fund manager contract",
          "_identity": "The identity contract"
        }
      },
      "currentDAIWorth()": {
        "details": "Calculates the worth of the staked cDAI tokens in DAI.",
        "return": "(uint256) The worth in DAI"
      },
      "currentUBIInterest()": {
        "details": "Calculates the current interest that was gained.",
        "return": "(uint256, uint256, uint256) The interest in cDAI, the interest in DAI, the amount which is not covered by precision of DAI"
      },
      "end()": {
        "details": "making the contract inactive NOTICE: this could theoretically result in future interest earned in cdai to remain locked but we dont expect any other stakers but us in SimpleDAIStaking"
      },
      "isOwner()": {
        "return": "true if `msg.sender` is the owner of the contract."
      },
      "isRegistered()": {
        "details": "function to see if an avatar has been set and if this scheme is registered",
        "return": "true if scheme is registered"
      },
      "isRegistered(address)": {
        "details": "function to see if an avatar has been set and if this scheme is registered",
        "return": "true if scheme is registered"
      },
      "owner()": {
        "return": "the address of the owner."
      },
      "pause()": {
        "details": "called by the owner to pause, triggers stopped state"
      },
      "paused()": {
        "return": "true if the contract is paused, false otherwise."
      },
      "recover(address)": {
        "details": "method to recover any stuck erc20 tokens (ie  compound COMP)",
        "params": {
          "_token": "the ERC20 token to recover"
        }
      },
      "renounceOwnership()": {
        "details": "Allows the current owner to relinquish control of the contract."
      },
      "setAvatar(address)": {
        "details": "Function to set a new avatar and controller for scheme can only be done by owner of scheme"
      },
      "setFundManager(address)": {
        "details": "Allows the DAO to change the fund manager contract address",
        "params": {
          "_fundManager": "Address of the new contract"
        }
      },
      "stakeDAI(uint256)": {
        "details": "Allows a staker to deposit DAI tokens. Notice that `approve` is needed to be executed before the execution of this method. Can be executed only when the contract is not paused.",
        "params": {
          "_amount": "The amount of DAI to stake"
        }
      },
      "start()": {
        "details": "Start function. Adds this contract to identity as a feeless scheme. Can only be called if scheme is registered"
      },
      "transferOwnership(address)": {
        "details": "Allows the current owner to transfer control of the contract to a newOwner.",
        "params": {
          "newOwner": "The address to transfer ownership to."
        }
      },
      "unpause()": {
        "details": "called by the owner to unpause, returns to normal state"
      },
      "withdrawStake()": {
        "details": "Withdraws the sender staked DAI."
      }
    },
    "title": "Staking contract that donates earned interest to the DAO allowing stakers to deposit DAI or withdraw their stake in DAI. The contract buys cDAI and can transfer the daily interest to the DAO"
  },
  "userdoc": {
    "methods": {
      "renounceOwnership()": {
        "notice": "Renouncing to ownership will leave the contract without an owner. It will not be possible to call the functions with the `onlyOwner` modifier anymore."
      }
    }
  }
}