Commit 51adb389 authored by Matthew Slipper's avatar Matthew Slipper Committed by GitHub

contracts: Deploy Teleportr to mainnet (#2476)

Co-authored-by: default avatarmergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
parent 25a796f1
---
'@eth-optimism/contracts': patch
---
Add Teleportr mainnet deployment
......@@ -95,6 +95,16 @@ StateCommitmentChain
</a>
</td>
</tr>
<tr>
<td>
TeleportrDeposit
</td>
<td align="center">
<a href="https://etherscan.io/address/0x52ec2F3d7C5977A8E558C8D9C6000B615098E8fC">
<code>0x52ec2F3d7C5977A8E558C8D9C6000B615098E8fC</code>
</a>
</td>
</tr>
</table>
## Layer 2 Contracts
......
{
"address": "0x52ec2F3d7C5977A8E558C8D9C6000B615098E8fC",
"abi": [
{
"inputs": [
{
"internalType": "uint256",
"name": "_minDepositAmount",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "_maxDepositAmount",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "_maxBalance",
"type": "uint256"
}
],
"stateMutability": "nonpayable",
"type": "constructor"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "owner",
"type": "address"
},
{
"indexed": false,
"internalType": "uint256",
"name": "balance",
"type": "uint256"
}
],
"name": "BalanceWithdrawn",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "uint256",
"name": "depositId",
"type": "uint256"
},
{
"indexed": true,
"internalType": "address",
"name": "emitter",
"type": "address"
},
{
"indexed": true,
"internalType": "uint256",
"name": "amount",
"type": "uint256"
}
],
"name": "EtherReceived",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": false,
"internalType": "uint256",
"name": "previousBalance",
"type": "uint256"
},
{
"indexed": false,
"internalType": "uint256",
"name": "newBalance",
"type": "uint256"
}
],
"name": "MaxBalanceSet",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": false,
"internalType": "uint256",
"name": "previousAmount",
"type": "uint256"
},
{
"indexed": false,
"internalType": "uint256",
"name": "newAmount",
"type": "uint256"
}
],
"name": "MaxDepositAmountSet",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": false,
"internalType": "uint256",
"name": "previousAmount",
"type": "uint256"
},
{
"indexed": false,
"internalType": "uint256",
"name": "newAmount",
"type": "uint256"
}
],
"name": "MinDepositAmountSet",
"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"
},
{
"inputs": [],
"name": "maxBalance",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "maxDepositAmount",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "minDepositAmount",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "owner",
"outputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "renounceOwnership",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "_maxDepositAmount",
"type": "uint256"
}
],
"name": "setMaxAmount",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "_maxBalance",
"type": "uint256"
}
],
"name": "setMaxBalance",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "_minDepositAmount",
"type": "uint256"
}
],
"name": "setMinAmount",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [],
"name": "totalDeposits",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "newOwner",
"type": "address"
}
],
"name": "transferOwnership",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [],
"name": "withdrawBalance",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"stateMutability": "payable",
"type": "receive"
}
],
"transactionHash": "0xb63a08a31db0fb45bf48836d0941dd30b094870905f838ee3c3ff237374edeaf",
"receipt": {
"to": null,
"from": "0xe07E50264CD86EC96a22C930f3581EFb46bA3A34",
"contractAddress": "0x52ec2F3d7C5977A8E558C8D9C6000B615098E8fC",
"transactionIndex": 284,
"gasUsed": "690034",
"logsBloom": "0x00000000000000000000000000000000000000000000000000800000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000020000000000000000000800200000000000000200000000004000400000000000000000000000000000000040000000000000000000000000000000000000040000000000000000000000000000000000020000000000000000000000000000000008000200000001000000400000000020000000000000000020000002000000000000000000000000008000000000000000000000000000020000",
"blockHash": "0xec5b8ac652db0c4eabeb18672080e7810982020558a38de0169b44a9efeffd9b",
"transactionHash": "0xb63a08a31db0fb45bf48836d0941dd30b094870905f838ee3c3ff237374edeaf",
"logs": [
{
"transactionIndex": 284,
"blockNumber": 14595007,
"transactionHash": "0xb63a08a31db0fb45bf48836d0941dd30b094870905f838ee3c3ff237374edeaf",
"address": "0x52ec2F3d7C5977A8E558C8D9C6000B615098E8fC",
"topics": [
"0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0",
"0x0000000000000000000000000000000000000000000000000000000000000000",
"0x000000000000000000000000e07e50264cd86ec96a22c930f3581efb46ba3a34"
],
"data": "0x",
"logIndex": 306,
"blockHash": "0xec5b8ac652db0c4eabeb18672080e7810982020558a38de0169b44a9efeffd9b"
},
{
"transactionIndex": 284,
"blockNumber": 14595007,
"transactionHash": "0xb63a08a31db0fb45bf48836d0941dd30b094870905f838ee3c3ff237374edeaf",
"address": "0x52ec2F3d7C5977A8E558C8D9C6000B615098E8fC",
"topics": [
"0x65779d3ca560e9bdec52d08ed75431a84df87cb7796f0e51965f6efc0f556c0f"
],
"data": "0x000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000005af3107a4000",
"logIndex": 307,
"blockHash": "0xec5b8ac652db0c4eabeb18672080e7810982020558a38de0169b44a9efeffd9b"
},
{
"transactionIndex": 284,
"blockNumber": 14595007,
"transactionHash": "0xb63a08a31db0fb45bf48836d0941dd30b094870905f838ee3c3ff237374edeaf",
"address": "0x52ec2F3d7C5977A8E558C8D9C6000B615098E8fC",
"topics": [
"0xb1e6cc560df1786578fd4d1fe6e046f089a0c3be401e999b51a5112437911797"
],
"data": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000de0b6b3a7640000",
"logIndex": 308,
"blockHash": "0xec5b8ac652db0c4eabeb18672080e7810982020558a38de0169b44a9efeffd9b"
},
{
"transactionIndex": 284,
"blockNumber": 14595007,
"transactionHash": "0xb63a08a31db0fb45bf48836d0941dd30b094870905f838ee3c3ff237374edeaf",
"address": "0x52ec2F3d7C5977A8E558C8D9C6000B615098E8fC",
"topics": [
"0x185c6391e7218e85de8a9346fc72024a0f88e1f04c186e6351230b93976ad50b"
],
"data": "0x000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003635c9adc5dea00000",
"logIndex": 309,
"blockHash": "0xec5b8ac652db0c4eabeb18672080e7810982020558a38de0169b44a9efeffd9b"
}
],
"blockNumber": 14595007,
"cumulativeGasUsed": "18549106",
"status": 1,
"byzantium": true
},
"args": [
"100000000000000",
"1000000000000000000",
"1000000000000000000000"
],
"solcInputHash": "ad04ab9565e42a9370aa7f055041028d",
"metadata": "{\"compiler\":{\"version\":\"0.8.9+commit.e5eed63a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_minDepositAmount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_maxDepositAmount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_maxBalance\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"balance\",\"type\":\"uint256\"}],\"name\":\"BalanceWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"depositId\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"emitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"EtherReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"previousBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"MaxBalanceSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"previousAmount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newAmount\",\"type\":\"uint256\"}],\"name\":\"MaxDepositAmountSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"previousAmount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newAmount\",\"type\":\"uint256\"}],\"name\":\"MinDepositAmountSet\",\"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\"},{\"inputs\":[],\"name\":\"maxBalance\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"maxDepositAmount\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"minDepositAmount\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"renounceOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_maxDepositAmount\",\"type\":\"uint256\"}],\"name\":\"setMaxAmount\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_maxBalance\",\"type\":\"uint256\"}],\"name\":\"setMaxBalance\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_minDepositAmount\",\"type\":\"uint256\"}],\"name\":\"setMinAmount\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"totalDeposits\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawBalance\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}],\"devdoc\":{\"events\":{\"BalanceWithdrawn(address,uint256)\":{\"params\":{\"balance\":\"The current contract balance paid to the owner.\",\"owner\":\"The current owner and recipient of the funds.\"}},\"EtherReceived(uint256,address,uint256)\":{\"params\":{\"amount\":\"The amount deposited by the payer.\",\"depositId\":\"A unique sequencer number identifying the deposit.\",\"emitter\":\"The sending address of the payer.\"}},\"MaxBalanceSet(uint256,uint256)\":{\"params\":{\"newBalance\":\"The new maximum contract balance.\",\"previousBalance\":\"The previous maximum contract balance.\"}},\"MaxDepositAmountSet(uint256,uint256)\":{\"params\":{\"newAmount\":\"The new maximum deposit amount.\",\"previousAmount\":\"The previous maximum deposit amount.\"}},\"MinDepositAmountSet(uint256,uint256)\":{\"params\":{\"newAmount\":\"The new minimum deposit amount.\",\"previousAmount\":\"The previous minimum deposit amount.\"}}},\"kind\":\"dev\",\"methods\":{\"constructor\":{\"params\":{\"_maxBalance\":\"The initial maximum contract balance.\",\"_maxDepositAmount\":\"The initial maximum deposit amount.\",\"_minDepositAmount\":\"The initial minimum deposit amount.\"}},\"owner()\":{\"details\":\"Returns the address of the current owner.\"},\"renounceOwnership()\":{\"details\":\"Leaves the contract without owner. It will not be possible to call `onlyOwner` functions anymore. Can only be called by the current owner. NOTE: Renouncing ownership will leave the contract without an owner, thereby removing any functionality that is only available to the owner.\"},\"setMaxAmount(uint256)\":{\"params\":{\"_maxDepositAmount\":\"The new maximum deposit amount.\"}},\"setMaxBalance(uint256)\":{\"params\":{\"_maxBalance\":\"The new maximum contract balance.\"}},\"setMinAmount(uint256)\":{\"params\":{\"_minDepositAmount\":\"The new minimum deposit amount.\"}},\"transferOwnership(address)\":{\"details\":\"Transfers ownership of the contract to a new account (`newOwner`). Can only be called by the current owner.\"}},\"title\":\"TeleportrDeposit Shout out to 0xclem for providing the inspiration for this contract: https://github.com/0xclem/teleportr/blob/main/contracts/BridgeDeposit.sol\",\"version\":1},\"userdoc\":{\"events\":{\"BalanceWithdrawn(address,uint256)\":{\"notice\":\"Emitted any time the balance is withdrawn by the owner.\"},\"EtherReceived(uint256,address,uint256)\":{\"notice\":\"Emitted any time a successful deposit is received.\"},\"MaxBalanceSet(uint256,uint256)\":{\"notice\":\"Emitted any time the contract maximum balance is set.\"},\"MaxDepositAmountSet(uint256,uint256)\":{\"notice\":\"Emitted any time the maximum deposit amount is set.\"},\"MinDepositAmountSet(uint256,uint256)\":{\"notice\":\"Emitted any time the minimum deposit amount is set.\"}},\"kind\":\"user\",\"methods\":{\"constructor\":{\"notice\":\"Initializes a new TeleportrDeposit contract.\"},\"maxBalance()\":{\"notice\":\"The maximum balance the contract can hold after a receive.\"},\"maxDepositAmount()\":{\"notice\":\"The maximum amount that be deposited in a receive.\"},\"minDepositAmount()\":{\"notice\":\"The minimum amount that be deposited in a receive.\"},\"setMaxAmount(uint256)\":{\"notice\":\"Sets the maximum amount that can be deposited in a receive.\"},\"setMaxBalance(uint256)\":{\"notice\":\"Sets the maximum balance the contract can hold after a receive.\"},\"setMinAmount(uint256)\":{\"notice\":\"Sets the minimum amount that can be deposited in a receive.\"},\"totalDeposits()\":{\"notice\":\"The total number of successful deposits received.\"},\"withdrawBalance()\":{\"notice\":\"Sends the contract's current balance to the owner.\"}},\"version\":1}},\"settings\":{\"compilationTarget\":{\"contracts/L1/teleportr/TeleportrDeposit.sol\":\"TeleportrDeposit\"},\"evmVersion\":\"london\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\",\"useLiteralContent\":true},\"optimizer\":{\"enabled\":true,\"runs\":10000},\"remappings\":[]},\"sources\":{\"@openzeppelin/contracts/access/Ownable.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n\\npragma solidity ^0.8.0;\\n\\nimport \\\"../utils/Context.sol\\\";\\n\\n/**\\n * @dev Contract module which provides a basic access control mechanism, where\\n * there is an account (an owner) that can be granted exclusive access to\\n * specific functions.\\n *\\n * By default, the owner account will be the one that deploys the contract. This\\n * can later be changed with {transferOwnership}.\\n *\\n * This module is used through inheritance. It will make available the modifier\\n * `onlyOwner`, which can be applied to your functions to restrict their use to\\n * the owner.\\n */\\nabstract contract Ownable is Context {\\n address private _owner;\\n\\n event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);\\n\\n /**\\n * @dev Initializes the contract setting the deployer as the initial owner.\\n */\\n constructor() {\\n _setOwner(_msgSender());\\n }\\n\\n /**\\n * @dev Returns the address of the current owner.\\n */\\n function owner() public view virtual returns (address) {\\n return _owner;\\n }\\n\\n /**\\n * @dev Throws if called by any account other than the owner.\\n */\\n modifier onlyOwner() {\\n require(owner() == _msgSender(), \\\"Ownable: caller is not the owner\\\");\\n _;\\n }\\n\\n /**\\n * @dev Leaves the contract without owner. It will not be possible to call\\n * `onlyOwner` functions anymore. Can only be called by the current owner.\\n *\\n * NOTE: Renouncing ownership will leave the contract without an owner,\\n * thereby removing any functionality that is only available to the owner.\\n */\\n function renounceOwnership() public virtual onlyOwner {\\n _setOwner(address(0));\\n }\\n\\n /**\\n * @dev Transfers ownership of the contract to a new account (`newOwner`).\\n * Can only be called by the current owner.\\n */\\n function transferOwnership(address newOwner) public virtual onlyOwner {\\n require(newOwner != address(0), \\\"Ownable: new owner is the zero address\\\");\\n _setOwner(newOwner);\\n }\\n\\n function _setOwner(address newOwner) private {\\n address oldOwner = _owner;\\n _owner = newOwner;\\n emit OwnershipTransferred(oldOwner, newOwner);\\n }\\n}\\n\",\"keccak256\":\"0x6bb804a310218875e89d12c053e94a13a4607cdf7cc2052f3e52bd32a0dc50a1\",\"license\":\"MIT\"},\"@openzeppelin/contracts/utils/Context.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n\\npragma solidity ^0.8.0;\\n\\n/**\\n * @dev Provides information about the current execution context, including the\\n * sender of the transaction and its data. While these are generally available\\n * via msg.sender and msg.data, they should not be accessed in such a direct\\n * manner, since when dealing with meta-transactions the account sending and\\n * paying for execution may not be the actual sender (as far as an application\\n * is concerned).\\n *\\n * This contract is only required for intermediate, library-like contracts.\\n */\\nabstract contract Context {\\n function _msgSender() internal view virtual returns (address) {\\n return msg.sender;\\n }\\n\\n function _msgData() internal view virtual returns (bytes calldata) {\\n return msg.data;\\n }\\n}\\n\",\"keccak256\":\"0x90565a39ae45c80f0468dc96c7b20d0afc3055f344c8203a0c9258239f350b9f\",\"license\":\"MIT\"},\"contracts/L1/teleportr/TeleportrDeposit.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\npragma solidity >=0.8.9;\\n\\nimport { Ownable } from \\\"@openzeppelin/contracts/access/Ownable.sol\\\";\\n\\n/**\\n * @title TeleportrDeposit\\n *\\n * Shout out to 0xclem for providing the inspiration for this contract:\\n * https://github.com/0xclem/teleportr/blob/main/contracts/BridgeDeposit.sol\\n */\\ncontract TeleportrDeposit is Ownable {\\n /// The minimum amount that be deposited in a receive.\\n uint256 public minDepositAmount;\\n /// The maximum amount that be deposited in a receive.\\n uint256 public maxDepositAmount;\\n /// The maximum balance the contract can hold after a receive.\\n uint256 public maxBalance;\\n /// The total number of successful deposits received.\\n uint256 public totalDeposits;\\n\\n /**\\n * @notice Emitted any time the minimum deposit amount is set.\\n * @param previousAmount The previous minimum deposit amount.\\n * @param newAmount The new minimum deposit amount.\\n */\\n event MinDepositAmountSet(uint256 previousAmount, uint256 newAmount);\\n\\n /**\\n * @notice Emitted any time the maximum deposit amount is set.\\n * @param previousAmount The previous maximum deposit amount.\\n * @param newAmount The new maximum deposit amount.\\n */\\n event MaxDepositAmountSet(uint256 previousAmount, uint256 newAmount);\\n\\n /**\\n * @notice Emitted any time the contract maximum balance is set.\\n * @param previousBalance The previous maximum contract balance.\\n * @param newBalance The new maximum contract balance.\\n */\\n event MaxBalanceSet(uint256 previousBalance, uint256 newBalance);\\n\\n /**\\n * @notice Emitted any time the balance is withdrawn by the owner.\\n * @param owner The current owner and recipient of the funds.\\n * @param balance The current contract balance paid to the owner.\\n */\\n event BalanceWithdrawn(address indexed owner, uint256 balance);\\n\\n /**\\n * @notice Emitted any time a successful deposit is received.\\n * @param depositId A unique sequencer number identifying the deposit.\\n * @param emitter The sending address of the payer.\\n * @param amount The amount deposited by the payer.\\n */\\n event EtherReceived(uint256 indexed depositId, address indexed emitter, uint256 indexed amount);\\n\\n /**\\n * @notice Initializes a new TeleportrDeposit contract.\\n * @param _minDepositAmount The initial minimum deposit amount.\\n * @param _maxDepositAmount The initial maximum deposit amount.\\n * @param _maxBalance The initial maximum contract balance.\\n */\\n constructor(\\n uint256 _minDepositAmount,\\n uint256 _maxDepositAmount,\\n uint256 _maxBalance\\n ) {\\n minDepositAmount = _minDepositAmount;\\n maxDepositAmount = _maxDepositAmount;\\n maxBalance = _maxBalance;\\n totalDeposits = 0;\\n emit MinDepositAmountSet(0, _minDepositAmount);\\n emit MaxDepositAmountSet(0, _maxDepositAmount);\\n emit MaxBalanceSet(0, _maxBalance);\\n }\\n\\n /**\\n * @notice Accepts deposits that will be disbursed to the sender's address on L2.\\n * The method reverts if the amount is less than the current\\n * minDepositAmount, the amount is greater than the current\\n * maxDepositAmount, or the amount causes the contract to exceed its maximum\\n * allowed balance.\\n */\\n receive() external payable {\\n require(msg.value >= minDepositAmount, \\\"Deposit amount is too small\\\");\\n require(msg.value <= maxDepositAmount, \\\"Deposit amount is too big\\\");\\n require(address(this).balance <= maxBalance, \\\"Contract max balance exceeded\\\");\\n\\n emit EtherReceived(totalDeposits, msg.sender, msg.value);\\n unchecked {\\n totalDeposits += 1;\\n }\\n }\\n\\n /**\\n * @notice Sends the contract's current balance to the owner.\\n */\\n function withdrawBalance() external onlyOwner {\\n address _owner = owner();\\n uint256 _balance = address(this).balance;\\n emit BalanceWithdrawn(_owner, _balance);\\n payable(_owner).transfer(_balance);\\n }\\n\\n /**\\n * @notice Sets the minimum amount that can be deposited in a receive.\\n * @param _minDepositAmount The new minimum deposit amount.\\n */\\n function setMinAmount(uint256 _minDepositAmount) external onlyOwner {\\n emit MinDepositAmountSet(minDepositAmount, _minDepositAmount);\\n minDepositAmount = _minDepositAmount;\\n }\\n\\n /**\\n * @notice Sets the maximum amount that can be deposited in a receive.\\n * @param _maxDepositAmount The new maximum deposit amount.\\n */\\n function setMaxAmount(uint256 _maxDepositAmount) external onlyOwner {\\n emit MaxDepositAmountSet(maxDepositAmount, _maxDepositAmount);\\n maxDepositAmount = _maxDepositAmount;\\n }\\n\\n /**\\n * @notice Sets the maximum balance the contract can hold after a receive.\\n * @param _maxBalance The new maximum contract balance.\\n */\\n function setMaxBalance(uint256 _maxBalance) external onlyOwner {\\n emit MaxBalanceSet(maxBalance, _maxBalance);\\n maxBalance = _maxBalance;\\n }\\n}\\n\",\"keccak256\":\"0x86af035f651f8d2d9b3acd8048d63ec95037c1411de9bd086c82afc6d9790a9d\",\"license\":\"MIT\"}},\"version\":1}",
"bytecode": "0x608060405234801561001057600080fd5b50604051610b4a380380610b4a83398101604081905261002f91610153565b61003833610103565b6001839055600282905560038190556000600481905560408051918252602082018590527f65779d3ca560e9bdec52d08ed75431a84df87cb7796f0e51965f6efc0f556c0f910160405180910390a16040805160008152602081018490527fb1e6cc560df1786578fd4d1fe6e046f089a0c3be401e999b51a5112437911797910160405180910390a16040805160008152602081018390527f185c6391e7218e85de8a9346fc72024a0f88e1f04c186e6351230b93976ad50b910160405180910390a1505050610181565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b60008060006060848603121561016857600080fd5b8351925060208401519150604084015190509250925092565b6109ba806101906000396000f3fe6080604052600436106100c05760003560e01c80637d882097116100745780638ed832711161004e5780638ed83271146103445780639d51d9b71461035a578063f2fde38b1461037a57600080fd5b80637d882097146102d9578063897b0637146102ef5780638da5cb5b1461030f57600080fd5b8063645006ca116100a5578063645006ca14610285578063715018a6146102ae57806373ad468a146102c357600080fd5b80634fe47f701461024e5780635fd8c7101461027057600080fd5b3661024957600154341015610136576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f4465706f73697420616d6f756e7420697320746f6f20736d616c6c000000000060448201526064015b60405180910390fd5b6002543411156101a2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f4465706f73697420616d6f756e7420697320746f6f2062696700000000000000604482015260640161012d565b60035447111561020e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f436f6e7472616374206d61782062616c616e6365206578636565646564000000604482015260640161012d565b600454604051349133917f2d27851832fcac28a0d4af1344f01fed7ffcfd15171c14c564a0c42aa57ae5c090600090a4600480546001019055005b600080fd5b34801561025a57600080fd5b5061026e61026936600461092e565b61039a565b005b34801561027c57600080fd5b5061026e61045c565b34801561029157600080fd5b5061029b60015481565b6040519081526020015b60405180910390f35b3480156102ba57600080fd5b5061026e610578565b3480156102cf57600080fd5b5061029b60035481565b3480156102e557600080fd5b5061029b60045481565b3480156102fb57600080fd5b5061026e61030a36600461092e565b610605565b34801561031b57600080fd5b5060005460405173ffffffffffffffffffffffffffffffffffffffff90911681526020016102a5565b34801561035057600080fd5b5061029b60025481565b34801561036657600080fd5b5061026e61037536600461092e565b6106c7565b34801561038657600080fd5b5061026e610395366004610947565b610789565b60005473ffffffffffffffffffffffffffffffffffffffff16331461041b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015260640161012d565b60025460408051918252602082018390527fb1e6cc560df1786578fd4d1fe6e046f089a0c3be401e999b51a5112437911797910160405180910390a1600255565b60005473ffffffffffffffffffffffffffffffffffffffff1633146104dd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015260640161012d565b6000546040805147808252915173ffffffffffffffffffffffffffffffffffffffff9093169283917fddc398b321237a8d40ac914388309c2f52a08c134e4dc4ce61e32f57cb7d80f1919081900360200190a260405173ffffffffffffffffffffffffffffffffffffffff83169082156108fc029083906000818181858888f19350505050158015610573573d6000803e3d6000fd5b505050565b60005473ffffffffffffffffffffffffffffffffffffffff1633146105f9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015260640161012d565b61060360006108b9565b565b60005473ffffffffffffffffffffffffffffffffffffffff163314610686576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015260640161012d565b60015460408051918252602082018390527f65779d3ca560e9bdec52d08ed75431a84df87cb7796f0e51965f6efc0f556c0f910160405180910390a1600155565b60005473ffffffffffffffffffffffffffffffffffffffff163314610748576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015260640161012d565b60035460408051918252602082018390527f185c6391e7218e85de8a9346fc72024a0f88e1f04c186e6351230b93976ad50b910160405180910390a1600355565b60005473ffffffffffffffffffffffffffffffffffffffff16331461080a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015260640161012d565b73ffffffffffffffffffffffffffffffffffffffff81166108ad576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f6464726573730000000000000000000000000000000000000000000000000000606482015260840161012d565b6108b6816108b9565b50565b6000805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b60006020828403121561094057600080fd5b5035919050565b60006020828403121561095957600080fd5b813573ffffffffffffffffffffffffffffffffffffffff8116811461097d57600080fd5b939250505056fea2646970667358221220b610d8106720e33f96db31f8c5c4f9cecb50144a2cf1e4049ac0216cd47d0eff64736f6c63430008090033",
"deployedBytecode": "0x6080604052600436106100c05760003560e01c80637d882097116100745780638ed832711161004e5780638ed83271146103445780639d51d9b71461035a578063f2fde38b1461037a57600080fd5b80637d882097146102d9578063897b0637146102ef5780638da5cb5b1461030f57600080fd5b8063645006ca116100a5578063645006ca14610285578063715018a6146102ae57806373ad468a146102c357600080fd5b80634fe47f701461024e5780635fd8c7101461027057600080fd5b3661024957600154341015610136576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f4465706f73697420616d6f756e7420697320746f6f20736d616c6c000000000060448201526064015b60405180910390fd5b6002543411156101a2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f4465706f73697420616d6f756e7420697320746f6f2062696700000000000000604482015260640161012d565b60035447111561020e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f436f6e7472616374206d61782062616c616e6365206578636565646564000000604482015260640161012d565b600454604051349133917f2d27851832fcac28a0d4af1344f01fed7ffcfd15171c14c564a0c42aa57ae5c090600090a4600480546001019055005b600080fd5b34801561025a57600080fd5b5061026e61026936600461092e565b61039a565b005b34801561027c57600080fd5b5061026e61045c565b34801561029157600080fd5b5061029b60015481565b6040519081526020015b60405180910390f35b3480156102ba57600080fd5b5061026e610578565b3480156102cf57600080fd5b5061029b60035481565b3480156102e557600080fd5b5061029b60045481565b3480156102fb57600080fd5b5061026e61030a36600461092e565b610605565b34801561031b57600080fd5b5060005460405173ffffffffffffffffffffffffffffffffffffffff90911681526020016102a5565b34801561035057600080fd5b5061029b60025481565b34801561036657600080fd5b5061026e61037536600461092e565b6106c7565b34801561038657600080fd5b5061026e610395366004610947565b610789565b60005473ffffffffffffffffffffffffffffffffffffffff16331461041b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015260640161012d565b60025460408051918252602082018390527fb1e6cc560df1786578fd4d1fe6e046f089a0c3be401e999b51a5112437911797910160405180910390a1600255565b60005473ffffffffffffffffffffffffffffffffffffffff1633146104dd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015260640161012d565b6000546040805147808252915173ffffffffffffffffffffffffffffffffffffffff9093169283917fddc398b321237a8d40ac914388309c2f52a08c134e4dc4ce61e32f57cb7d80f1919081900360200190a260405173ffffffffffffffffffffffffffffffffffffffff83169082156108fc029083906000818181858888f19350505050158015610573573d6000803e3d6000fd5b505050565b60005473ffffffffffffffffffffffffffffffffffffffff1633146105f9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015260640161012d565b61060360006108b9565b565b60005473ffffffffffffffffffffffffffffffffffffffff163314610686576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015260640161012d565b60015460408051918252602082018390527f65779d3ca560e9bdec52d08ed75431a84df87cb7796f0e51965f6efc0f556c0f910160405180910390a1600155565b60005473ffffffffffffffffffffffffffffffffffffffff163314610748576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015260640161012d565b60035460408051918252602082018390527f185c6391e7218e85de8a9346fc72024a0f88e1f04c186e6351230b93976ad50b910160405180910390a1600355565b60005473ffffffffffffffffffffffffffffffffffffffff16331461080a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015260640161012d565b73ffffffffffffffffffffffffffffffffffffffff81166108ad576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f6464726573730000000000000000000000000000000000000000000000000000606482015260840161012d565b6108b6816108b9565b50565b6000805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b60006020828403121561094057600080fd5b5035919050565b60006020828403121561095957600080fd5b813573ffffffffffffffffffffffffffffffffffffffff8116811461097d57600080fd5b939250505056fea2646970667358221220b610d8106720e33f96db31f8c5c4f9cecb50144a2cf1e4049ac0216cd47d0eff64736f6c63430008090033",
"devdoc": {
"events": {
"BalanceWithdrawn(address,uint256)": {
"params": {
"balance": "The current contract balance paid to the owner.",
"owner": "The current owner and recipient of the funds."
}
},
"EtherReceived(uint256,address,uint256)": {
"params": {
"amount": "The amount deposited by the payer.",
"depositId": "A unique sequencer number identifying the deposit.",
"emitter": "The sending address of the payer."
}
},
"MaxBalanceSet(uint256,uint256)": {
"params": {
"newBalance": "The new maximum contract balance.",
"previousBalance": "The previous maximum contract balance."
}
},
"MaxDepositAmountSet(uint256,uint256)": {
"params": {
"newAmount": "The new maximum deposit amount.",
"previousAmount": "The previous maximum deposit amount."
}
},
"MinDepositAmountSet(uint256,uint256)": {
"params": {
"newAmount": "The new minimum deposit amount.",
"previousAmount": "The previous minimum deposit amount."
}
}
},
"kind": "dev",
"methods": {
"constructor": {
"params": {
"_maxBalance": "The initial maximum contract balance.",
"_maxDepositAmount": "The initial maximum deposit amount.",
"_minDepositAmount": "The initial minimum deposit amount."
}
},
"owner()": {
"details": "Returns the address of the current owner."
},
"renounceOwnership()": {
"details": "Leaves the contract without owner. It will not be possible to call `onlyOwner` functions anymore. Can only be called by the current owner. NOTE: Renouncing ownership will leave the contract without an owner, thereby removing any functionality that is only available to the owner."
},
"setMaxAmount(uint256)": {
"params": {
"_maxDepositAmount": "The new maximum deposit amount."
}
},
"setMaxBalance(uint256)": {
"params": {
"_maxBalance": "The new maximum contract balance."
}
},
"setMinAmount(uint256)": {
"params": {
"_minDepositAmount": "The new minimum deposit amount."
}
},
"transferOwnership(address)": {
"details": "Transfers ownership of the contract to a new account (`newOwner`). Can only be called by the current owner."
}
},
"title": "TeleportrDeposit Shout out to 0xclem for providing the inspiration for this contract: https://github.com/0xclem/teleportr/blob/main/contracts/BridgeDeposit.sol",
"version": 1
},
"userdoc": {
"events": {
"BalanceWithdrawn(address,uint256)": {
"notice": "Emitted any time the balance is withdrawn by the owner."
},
"EtherReceived(uint256,address,uint256)": {
"notice": "Emitted any time a successful deposit is received."
},
"MaxBalanceSet(uint256,uint256)": {
"notice": "Emitted any time the contract maximum balance is set."
},
"MaxDepositAmountSet(uint256,uint256)": {
"notice": "Emitted any time the maximum deposit amount is set."
},
"MinDepositAmountSet(uint256,uint256)": {
"notice": "Emitted any time the minimum deposit amount is set."
}
},
"kind": "user",
"methods": {
"constructor": {
"notice": "Initializes a new TeleportrDeposit contract."
},
"maxBalance()": {
"notice": "The maximum balance the contract can hold after a receive."
},
"maxDepositAmount()": {
"notice": "The maximum amount that be deposited in a receive."
},
"minDepositAmount()": {
"notice": "The minimum amount that be deposited in a receive."
},
"setMaxAmount(uint256)": {
"notice": "Sets the maximum amount that can be deposited in a receive."
},
"setMaxBalance(uint256)": {
"notice": "Sets the maximum balance the contract can hold after a receive."
},
"setMinAmount(uint256)": {
"notice": "Sets the minimum amount that can be deposited in a receive."
},
"totalDeposits()": {
"notice": "The total number of successful deposits received."
},
"withdrawBalance()": {
"notice": "Sends the contract's current balance to the owner."
}
},
"version": 1
},
"storageLayout": {
"storage": [
{
"astId": 393,
"contract": "contracts/L1/teleportr/TeleportrDeposit.sol:TeleportrDeposit",
"label": "_owner",
"offset": 0,
"slot": "0",
"type": "t_address"
},
{
"astId": 5028,
"contract": "contracts/L1/teleportr/TeleportrDeposit.sol:TeleportrDeposit",
"label": "minDepositAmount",
"offset": 0,
"slot": "1",
"type": "t_uint256"
},
{
"astId": 5031,
"contract": "contracts/L1/teleportr/TeleportrDeposit.sol:TeleportrDeposit",
"label": "maxDepositAmount",
"offset": 0,
"slot": "2",
"type": "t_uint256"
},
{
"astId": 5034,
"contract": "contracts/L1/teleportr/TeleportrDeposit.sol:TeleportrDeposit",
"label": "maxBalance",
"offset": 0,
"slot": "3",
"type": "t_uint256"
},
{
"astId": 5037,
"contract": "contracts/L1/teleportr/TeleportrDeposit.sol:TeleportrDeposit",
"label": "totalDeposits",
"offset": 0,
"slot": "4",
"type": "t_uint256"
}
],
"types": {
"t_address": {
"encoding": "inplace",
"label": "address",
"numberOfBytes": "20"
},
"t_uint256": {
"encoding": "inplace",
"label": "uint256",
"numberOfBytes": "32"
}
}
}
}
\ No newline at end of file
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
{
"address": "0x52ec2F3d7C5977A8E558C8D9C6000B615098E8fC",
"abi": [
{
"inputs": [],
"stateMutability": "nonpayable",
"type": "constructor"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "owner",
"type": "address"
},
{
"indexed": false,
"internalType": "uint256",
"name": "balance",
"type": "uint256"
}
],
"name": "BalanceWithdrawn",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "uint256",
"name": "depositId",
"type": "uint256"
},
{
"indexed": true,
"internalType": "address",
"name": "to",
"type": "address"
},
{
"indexed": false,
"internalType": "uint256",
"name": "amount",
"type": "uint256"
}
],
"name": "DisbursementFailed",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "uint256",
"name": "depositId",
"type": "uint256"
},
{
"indexed": true,
"internalType": "address",
"name": "to",
"type": "address"
},
{
"indexed": false,
"internalType": "uint256",
"name": "amount",
"type": "uint256"
}
],
"name": "DisbursementSuccess",
"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"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "_nextDepositId",
"type": "uint256"
},
{
"components": [
{
"internalType": "uint256",
"name": "amount",
"type": "uint256"
},
{
"internalType": "address",
"name": "addr",
"type": "address"
}
],
"internalType": "struct TeleportrDisburser.Disbursement[]",
"name": "_disbursements",
"type": "tuple[]"
}
],
"name": "disburse",
"outputs": [],
"stateMutability": "payable",
"type": "function"
},
{
"inputs": [],
"name": "owner",
"outputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "renounceOwnership",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [],
"name": "totalDisbursements",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "newOwner",
"type": "address"
}
],
"name": "transferOwnership",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [],
"name": "withdrawBalance",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
}
],
"transactionHash": "0x318376cdfce4b2954986e7938c14fbd61ff567c7ad4a9de0b1c0116297824427",
"receipt": {
"to": null,
"from": "0xe07E50264CD86EC96a22C930f3581EFb46bA3A34",
"contractAddress": "0x52ec2F3d7C5977A8E558C8D9C6000B615098E8fC",
"transactionIndex": 0,
"gasUsed": "622414",
"logsBloom": "0x00000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000020000000000000000000800200000000000000200000000004000400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000008000000000001000000000000000000000000000000000020000002000000000000000000000000000000000000000000000000000000000000",
"blockHash": "0x9fc3f4663da5721a769959107ea8f364d221c982c2d1caf661fa9394a61ef150",
"transactionHash": "0x318376cdfce4b2954986e7938c14fbd61ff567c7ad4a9de0b1c0116297824427",
"logs": [
{
"transactionIndex": 0,
"blockNumber": 5884959,
"transactionHash": "0x318376cdfce4b2954986e7938c14fbd61ff567c7ad4a9de0b1c0116297824427",
"address": "0x52ec2F3d7C5977A8E558C8D9C6000B615098E8fC",
"topics": [
"0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0",
"0x0000000000000000000000000000000000000000000000000000000000000000",
"0x000000000000000000000000e07e50264cd86ec96a22c930f3581efb46ba3a34"
],
"data": "0x",
"logIndex": 0,
"blockHash": "0x9fc3f4663da5721a769959107ea8f364d221c982c2d1caf661fa9394a61ef150"
}
],
"blockNumber": 5884959,
"cumulativeGasUsed": "622414",
"status": 1,
"byzantium": true
},
"args": [],
"solcInputHash": "ad04ab9565e42a9370aa7f055041028d",
"metadata": "{\"compiler\":{\"version\":\"0.8.9+commit.e5eed63a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"balance\",\"type\":\"uint256\"}],\"name\":\"BalanceWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"depositId\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"DisbursementFailed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"depositId\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"DisbursementSuccess\",\"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\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_nextDepositId\",\"type\":\"uint256\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"}],\"internalType\":\"struct TeleportrDisburser.Disbursement[]\",\"name\":\"_disbursements\",\"type\":\"tuple[]\"}],\"name\":\"disburse\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"renounceOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"totalDisbursements\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawBalance\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}],\"devdoc\":{\"events\":{\"BalanceWithdrawn(address,uint256)\":{\"params\":{\"balance\":\"The current contract balance paid to the owner.\",\"owner\":\"The current owner and recipient of the funds.\"}},\"DisbursementFailed(uint256,address,uint256)\":{\"params\":{\"amount\":\"The amount intended to be sent to the recipient.\",\"depositId\":\"The unique sequence number identifying the deposit.\",\"to\":\"The intended recipient of the disbursement.\"}},\"DisbursementSuccess(uint256,address,uint256)\":{\"params\":{\"amount\":\"The amount sent to the recipient.\",\"depositId\":\"The unique sequence number identifying the deposit.\",\"to\":\"The recipient of the disbursement.\"}}},\"kind\":\"dev\",\"methods\":{\"disburse(uint256,(uint256,address)[])\":{\"params\":{\"_disbursements\":\"A list of Disbursements to process.\",\"_nextDepositId\":\"The depositId of the first Dispursement.\"}},\"owner()\":{\"details\":\"Returns the address of the current owner.\"},\"renounceOwnership()\":{\"details\":\"Leaves the contract without owner. It will not be possible to call `onlyOwner` functions anymore. Can only be called by the current owner. NOTE: Renouncing ownership will leave the contract without an owner, thereby removing any functionality that is only available to the owner.\"},\"transferOwnership(address)\":{\"details\":\"Transfers ownership of the contract to a new account (`newOwner`). Can only be called by the current owner.\"}},\"title\":\"TeleportrDisburser\",\"version\":1},\"userdoc\":{\"events\":{\"BalanceWithdrawn(address,uint256)\":{\"notice\":\"Emitted any time the balance is withdrawn by the owner.\"},\"DisbursementFailed(uint256,address,uint256)\":{\"notice\":\"Emitted any time a disbursement fails to send.\"},\"DisbursementSuccess(uint256,address,uint256)\":{\"notice\":\"Emitted any time a disbursement is successfuly sent.\"}},\"kind\":\"user\",\"methods\":{\"constructor\":{\"notice\":\"Initializes a new TeleportrDisburser contract.\"},\"disburse(uint256,(uint256,address)[])\":{\"notice\":\"Accepts a list of Disbursements and forwards the amount paid to the contract to each recipient. The method reverts if there are zero disbursements, the total amount to forward differs from the amount sent in the transaction, or the _nextDepositId is unexpected. Failed disbursements will not cause the method to revert, but will instead be held by the contract and availabe for the owner to withdraw.\"},\"totalDisbursements()\":{\"notice\":\"The total number of disbursements processed.\"},\"withdrawBalance()\":{\"notice\":\"Sends the contract's current balance to the owner.\"}},\"version\":1}},\"settings\":{\"compilationTarget\":{\"contracts/L2/teleportr/TeleportrDisburser.sol\":\"TeleportrDisburser\"},\"evmVersion\":\"london\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\",\"useLiteralContent\":true},\"optimizer\":{\"enabled\":true,\"runs\":10000},\"remappings\":[]},\"sources\":{\"@openzeppelin/contracts/access/Ownable.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n\\npragma solidity ^0.8.0;\\n\\nimport \\\"../utils/Context.sol\\\";\\n\\n/**\\n * @dev Contract module which provides a basic access control mechanism, where\\n * there is an account (an owner) that can be granted exclusive access to\\n * specific functions.\\n *\\n * By default, the owner account will be the one that deploys the contract. This\\n * can later be changed with {transferOwnership}.\\n *\\n * This module is used through inheritance. It will make available the modifier\\n * `onlyOwner`, which can be applied to your functions to restrict their use to\\n * the owner.\\n */\\nabstract contract Ownable is Context {\\n address private _owner;\\n\\n event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);\\n\\n /**\\n * @dev Initializes the contract setting the deployer as the initial owner.\\n */\\n constructor() {\\n _setOwner(_msgSender());\\n }\\n\\n /**\\n * @dev Returns the address of the current owner.\\n */\\n function owner() public view virtual returns (address) {\\n return _owner;\\n }\\n\\n /**\\n * @dev Throws if called by any account other than the owner.\\n */\\n modifier onlyOwner() {\\n require(owner() == _msgSender(), \\\"Ownable: caller is not the owner\\\");\\n _;\\n }\\n\\n /**\\n * @dev Leaves the contract without owner. It will not be possible to call\\n * `onlyOwner` functions anymore. Can only be called by the current owner.\\n *\\n * NOTE: Renouncing ownership will leave the contract without an owner,\\n * thereby removing any functionality that is only available to the owner.\\n */\\n function renounceOwnership() public virtual onlyOwner {\\n _setOwner(address(0));\\n }\\n\\n /**\\n * @dev Transfers ownership of the contract to a new account (`newOwner`).\\n * Can only be called by the current owner.\\n */\\n function transferOwnership(address newOwner) public virtual onlyOwner {\\n require(newOwner != address(0), \\\"Ownable: new owner is the zero address\\\");\\n _setOwner(newOwner);\\n }\\n\\n function _setOwner(address newOwner) private {\\n address oldOwner = _owner;\\n _owner = newOwner;\\n emit OwnershipTransferred(oldOwner, newOwner);\\n }\\n}\\n\",\"keccak256\":\"0x6bb804a310218875e89d12c053e94a13a4607cdf7cc2052f3e52bd32a0dc50a1\",\"license\":\"MIT\"},\"@openzeppelin/contracts/utils/Context.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n\\npragma solidity ^0.8.0;\\n\\n/**\\n * @dev Provides information about the current execution context, including the\\n * sender of the transaction and its data. While these are generally available\\n * via msg.sender and msg.data, they should not be accessed in such a direct\\n * manner, since when dealing with meta-transactions the account sending and\\n * paying for execution may not be the actual sender (as far as an application\\n * is concerned).\\n *\\n * This contract is only required for intermediate, library-like contracts.\\n */\\nabstract contract Context {\\n function _msgSender() internal view virtual returns (address) {\\n return msg.sender;\\n }\\n\\n function _msgData() internal view virtual returns (bytes calldata) {\\n return msg.data;\\n }\\n}\\n\",\"keccak256\":\"0x90565a39ae45c80f0468dc96c7b20d0afc3055f344c8203a0c9258239f350b9f\",\"license\":\"MIT\"},\"contracts/L2/teleportr/TeleportrDisburser.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\npragma solidity >=0.8.9;\\n\\nimport { Ownable } from \\\"@openzeppelin/contracts/access/Ownable.sol\\\";\\n\\n/**\\n * @title TeleportrDisburser\\n */\\ncontract TeleportrDisburser is Ownable {\\n /**\\n * @notice A struct holding the address and amount to disbursement.\\n */\\n struct Disbursement {\\n uint256 amount;\\n address addr;\\n }\\n\\n /// The total number of disbursements processed.\\n uint256 public totalDisbursements;\\n\\n /**\\n * @notice Emitted any time the balance is withdrawn by the owner.\\n * @param owner The current owner and recipient of the funds.\\n * @param balance The current contract balance paid to the owner.\\n */\\n event BalanceWithdrawn(address indexed owner, uint256 balance);\\n\\n /**\\n * @notice Emitted any time a disbursement is successfuly sent.\\n * @param depositId The unique sequence number identifying the deposit.\\n * @param to The recipient of the disbursement.\\n * @param amount The amount sent to the recipient.\\n */\\n event DisbursementSuccess(uint256 indexed depositId, address indexed to, uint256 amount);\\n\\n /**\\n * @notice Emitted any time a disbursement fails to send.\\n * @param depositId The unique sequence number identifying the deposit.\\n * @param to The intended recipient of the disbursement.\\n * @param amount The amount intended to be sent to the recipient.\\n */\\n event DisbursementFailed(uint256 indexed depositId, address indexed to, uint256 amount);\\n\\n /**\\n * @notice Initializes a new TeleportrDisburser contract.\\n */\\n constructor() {\\n totalDisbursements = 0;\\n }\\n\\n /**\\n * @notice Accepts a list of Disbursements and forwards the amount paid to\\n * the contract to each recipient. The method reverts if there are zero\\n * disbursements, the total amount to forward differs from the amount sent\\n * in the transaction, or the _nextDepositId is unexpected. Failed\\n * disbursements will not cause the method to revert, but will instead be\\n * held by the contract and availabe for the owner to withdraw.\\n * @param _nextDepositId The depositId of the first Dispursement.\\n * @param _disbursements A list of Disbursements to process.\\n */\\n function disburse(uint256 _nextDepositId, Disbursement[] calldata _disbursements)\\n external\\n payable\\n onlyOwner\\n {\\n // Ensure there are disbursements to process.\\n uint256 _numDisbursements = _disbursements.length;\\n require(_numDisbursements > 0, \\\"No disbursements\\\");\\n\\n // Ensure the _nextDepositId matches our expected value.\\n uint256 _depositId = totalDisbursements;\\n require(_depositId == _nextDepositId, \\\"Unexpected next deposit id\\\");\\n unchecked {\\n totalDisbursements += _numDisbursements;\\n }\\n\\n // Ensure the amount sent in the transaction is equal to the sum of the\\n // disbursements.\\n uint256 _totalDisbursed = 0;\\n for (uint256 i = 0; i < _numDisbursements; i++) {\\n _totalDisbursed += _disbursements[i].amount;\\n }\\n require(_totalDisbursed == msg.value, \\\"Disbursement total != amount sent\\\");\\n\\n // Process disbursements.\\n for (uint256 i = 0; i < _numDisbursements; i++) {\\n uint256 _amount = _disbursements[i].amount;\\n address _addr = _disbursements[i].addr;\\n\\n // Deliver the dispursement amount to the receiver. If the\\n // disbursement fails, the amount will be kept by the contract\\n // rather than reverting to prevent blocking progress on other\\n // disbursements.\\n\\n // slither-disable-next-line calls-loop,reentrancy-events\\n (bool success, ) = _addr.call{ value: _amount, gas: 2300 }(\\\"\\\");\\n if (success) emit DisbursementSuccess(_depositId, _addr, _amount);\\n else emit DisbursementFailed(_depositId, _addr, _amount);\\n\\n unchecked {\\n _depositId += 1;\\n }\\n }\\n }\\n\\n /**\\n * @notice Sends the contract's current balance to the owner.\\n */\\n function withdrawBalance() external onlyOwner {\\n address _owner = owner();\\n uint256 balance = address(this).balance;\\n emit BalanceWithdrawn(_owner, balance);\\n payable(_owner).transfer(balance);\\n }\\n}\\n\",\"keccak256\":\"0xd50edb075f01356e6bde13bceca93749253390e714d9a55e16013b8216ac8344\",\"license\":\"MIT\"}},\"version\":1}",
"bytecode": "0x608060405234801561001057600080fd5b5061001a33610024565b6000600155610074565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6109e1806100836000396000f3fe6080604052600436106100655760003560e01c80638da5cb5b116100435780638da5cb5b146100bf578063ad48144d146100f4578063f2fde38b1461010757600080fd5b806325999e7f1461006a5780635fd8c71014610093578063715018a6146100aa575b600080fd5b34801561007657600080fd5b5061008060015481565b6040519081526020015b60405180910390f35b34801561009f57600080fd5b506100a8610127565b005b3480156100b657600080fd5b506100a8610248565b3480156100cb57600080fd5b5060005460405173ffffffffffffffffffffffffffffffffffffffff909116815260200161008a565b6100a8610102366004610840565b6102d5565b34801561011357600080fd5b506100a86101223660046108bf565b61069b565b60005473ffffffffffffffffffffffffffffffffffffffff1633146101ad576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064015b60405180910390fd5b6000546040805147808252915173ffffffffffffffffffffffffffffffffffffffff9093169283917fddc398b321237a8d40ac914388309c2f52a08c134e4dc4ce61e32f57cb7d80f1919081900360200190a260405173ffffffffffffffffffffffffffffffffffffffff83169082156108fc029083906000818181858888f19350505050158015610243573d6000803e3d6000fd5b505050565b60005473ffffffffffffffffffffffffffffffffffffffff1633146102c9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016101a4565b6102d360006107cb565b565b60005473ffffffffffffffffffffffffffffffffffffffff163314610356576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016101a4565b80806103be576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f4e6f2064697362757273656d656e74730000000000000000000000000000000060448201526064016101a4565b60015484811461042a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f556e6578706563746564206e657874206465706f73697420696400000000000060448201526064016101a4565b60018054830190556000805b8381101561047757858582818110610450576104506108fc565b610463926040909102013590508361095a565b91508061046f81610972565b915050610436565b50348114610507576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f44697362757273656d656e7420746f74616c20213d20616d6f756e742073656e60448201527f740000000000000000000000000000000000000000000000000000000000000060648201526084016101a4565b60005b83811015610692576000868683818110610526576105266108fc565b9050604002016000013590506000878784818110610546576105466108fc565b905060400201602001602081019061055e91906108bf565b905060008173ffffffffffffffffffffffffffffffffffffffff16836108fc90604051600060405180830381858888f193505050503d80600081146105bf576040519150601f19603f3d011682016040523d82523d6000602084013e6105c4565b606091505b505090508015610624578173ffffffffffffffffffffffffffffffffffffffff16867feaa22fd2d7b875476355b32cf719794faf9d91b66e73bc6375a053cace9caaee8560405161061791815260200190565b60405180910390a3610676565b8173ffffffffffffffffffffffffffffffffffffffff16867f9b478c095979d3d3a7d602ffd9ee1f0843204d853558ae0882c8fcc0a5bc78cf8560405161066d91815260200190565b60405180910390a35b600186019550505050808061068a90610972565b91505061050a565b50505050505050565b60005473ffffffffffffffffffffffffffffffffffffffff16331461071c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016101a4565b73ffffffffffffffffffffffffffffffffffffffff81166107bf576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f646472657373000000000000000000000000000000000000000000000000000060648201526084016101a4565b6107c8816107cb565b50565b6000805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b60008060006040848603121561085557600080fd5b83359250602084013567ffffffffffffffff8082111561087457600080fd5b818601915086601f83011261088857600080fd5b81358181111561089757600080fd5b8760208260061b85010111156108ac57600080fd5b6020830194508093505050509250925092565b6000602082840312156108d157600080fd5b813573ffffffffffffffffffffffffffffffffffffffff811681146108f557600080fd5b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6000821982111561096d5761096d61092b565b500190565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8214156109a4576109a461092b565b506001019056fea26469706673582212209c98cb9cc04bc2bf5e8c0baf23ef87d045122afe6cfbb0e3c31bd854dd7fad7d64736f6c63430008090033",
"deployedBytecode": "0x6080604052600436106100655760003560e01c80638da5cb5b116100435780638da5cb5b146100bf578063ad48144d146100f4578063f2fde38b1461010757600080fd5b806325999e7f1461006a5780635fd8c71014610093578063715018a6146100aa575b600080fd5b34801561007657600080fd5b5061008060015481565b6040519081526020015b60405180910390f35b34801561009f57600080fd5b506100a8610127565b005b3480156100b657600080fd5b506100a8610248565b3480156100cb57600080fd5b5060005460405173ffffffffffffffffffffffffffffffffffffffff909116815260200161008a565b6100a8610102366004610840565b6102d5565b34801561011357600080fd5b506100a86101223660046108bf565b61069b565b60005473ffffffffffffffffffffffffffffffffffffffff1633146101ad576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064015b60405180910390fd5b6000546040805147808252915173ffffffffffffffffffffffffffffffffffffffff9093169283917fddc398b321237a8d40ac914388309c2f52a08c134e4dc4ce61e32f57cb7d80f1919081900360200190a260405173ffffffffffffffffffffffffffffffffffffffff83169082156108fc029083906000818181858888f19350505050158015610243573d6000803e3d6000fd5b505050565b60005473ffffffffffffffffffffffffffffffffffffffff1633146102c9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016101a4565b6102d360006107cb565b565b60005473ffffffffffffffffffffffffffffffffffffffff163314610356576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016101a4565b80806103be576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f4e6f2064697362757273656d656e74730000000000000000000000000000000060448201526064016101a4565b60015484811461042a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f556e6578706563746564206e657874206465706f73697420696400000000000060448201526064016101a4565b60018054830190556000805b8381101561047757858582818110610450576104506108fc565b610463926040909102013590508361095a565b91508061046f81610972565b915050610436565b50348114610507576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f44697362757273656d656e7420746f74616c20213d20616d6f756e742073656e60448201527f740000000000000000000000000000000000000000000000000000000000000060648201526084016101a4565b60005b83811015610692576000868683818110610526576105266108fc565b9050604002016000013590506000878784818110610546576105466108fc565b905060400201602001602081019061055e91906108bf565b905060008173ffffffffffffffffffffffffffffffffffffffff16836108fc90604051600060405180830381858888f193505050503d80600081146105bf576040519150601f19603f3d011682016040523d82523d6000602084013e6105c4565b606091505b505090508015610624578173ffffffffffffffffffffffffffffffffffffffff16867feaa22fd2d7b875476355b32cf719794faf9d91b66e73bc6375a053cace9caaee8560405161061791815260200190565b60405180910390a3610676565b8173ffffffffffffffffffffffffffffffffffffffff16867f9b478c095979d3d3a7d602ffd9ee1f0843204d853558ae0882c8fcc0a5bc78cf8560405161066d91815260200190565b60405180910390a35b600186019550505050808061068a90610972565b91505061050a565b50505050505050565b60005473ffffffffffffffffffffffffffffffffffffffff16331461071c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016101a4565b73ffffffffffffffffffffffffffffffffffffffff81166107bf576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f646472657373000000000000000000000000000000000000000000000000000060648201526084016101a4565b6107c8816107cb565b50565b6000805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b60008060006040848603121561085557600080fd5b83359250602084013567ffffffffffffffff8082111561087457600080fd5b818601915086601f83011261088857600080fd5b81358181111561089757600080fd5b8760208260061b85010111156108ac57600080fd5b6020830194508093505050509250925092565b6000602082840312156108d157600080fd5b813573ffffffffffffffffffffffffffffffffffffffff811681146108f557600080fd5b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6000821982111561096d5761096d61092b565b500190565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8214156109a4576109a461092b565b506001019056fea26469706673582212209c98cb9cc04bc2bf5e8c0baf23ef87d045122afe6cfbb0e3c31bd854dd7fad7d64736f6c63430008090033",
"devdoc": {
"events": {
"BalanceWithdrawn(address,uint256)": {
"params": {
"balance": "The current contract balance paid to the owner.",
"owner": "The current owner and recipient of the funds."
}
},
"DisbursementFailed(uint256,address,uint256)": {
"params": {
"amount": "The amount intended to be sent to the recipient.",
"depositId": "The unique sequence number identifying the deposit.",
"to": "The intended recipient of the disbursement."
}
},
"DisbursementSuccess(uint256,address,uint256)": {
"params": {
"amount": "The amount sent to the recipient.",
"depositId": "The unique sequence number identifying the deposit.",
"to": "The recipient of the disbursement."
}
}
},
"kind": "dev",
"methods": {
"disburse(uint256,(uint256,address)[])": {
"params": {
"_disbursements": "A list of Disbursements to process.",
"_nextDepositId": "The depositId of the first Dispursement."
}
},
"owner()": {
"details": "Returns the address of the current owner."
},
"renounceOwnership()": {
"details": "Leaves the contract without owner. It will not be possible to call `onlyOwner` functions anymore. Can only be called by the current owner. NOTE: Renouncing ownership will leave the contract without an owner, thereby removing any functionality that is only available to the owner."
},
"transferOwnership(address)": {
"details": "Transfers ownership of the contract to a new account (`newOwner`). Can only be called by the current owner."
}
},
"title": "TeleportrDisburser",
"version": 1
},
"userdoc": {
"events": {
"BalanceWithdrawn(address,uint256)": {
"notice": "Emitted any time the balance is withdrawn by the owner."
},
"DisbursementFailed(uint256,address,uint256)": {
"notice": "Emitted any time a disbursement fails to send."
},
"DisbursementSuccess(uint256,address,uint256)": {
"notice": "Emitted any time a disbursement is successfuly sent."
}
},
"kind": "user",
"methods": {
"constructor": {
"notice": "Initializes a new TeleportrDisburser contract."
},
"disburse(uint256,(uint256,address)[])": {
"notice": "Accepts a list of Disbursements and forwards the amount paid to the contract to each recipient. The method reverts if there are zero disbursements, the total amount to forward differs from the amount sent in the transaction, or the _nextDepositId is unexpected. Failed disbursements will not cause the method to revert, but will instead be held by the contract and availabe for the owner to withdraw."
},
"totalDisbursements()": {
"notice": "The total number of disbursements processed."
},
"withdrawBalance()": {
"notice": "Sends the contract's current balance to the owner."
}
},
"version": 1
},
"storageLayout": {
"storage": [
{
"astId": 393,
"contract": "contracts/L2/teleportr/TeleportrDisburser.sol:TeleportrDisburser",
"label": "_owner",
"offset": 0,
"slot": "0",
"type": "t_address"
},
{
"astId": 6419,
"contract": "contracts/L2/teleportr/TeleportrDisburser.sol:TeleportrDisburser",
"label": "totalDisbursements",
"offset": 0,
"slot": "1",
"type": "t_uint256"
}
],
"types": {
"t_address": {
"encoding": "inplace",
"label": "address",
"numberOfBytes": "20"
},
"t_uint256": {
"encoding": "inplace",
"label": "uint256",
"numberOfBytes": "32"
}
}
}
}
\ No newline at end of file
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -110,7 +110,10 @@ const config: HardhatUserConfig = {
outputFile: process.env.CI ? 'gas-report.txt' : undefined,
},
etherscan: {
apiKey: process.env.ETHERSCAN_API_KEY,
apiKey: {
mainnet: process.env.ETHERSCAN_API_KEY,
optimisticEthereum: process.env.OPTIMISTIC_ETHERSCAN_API_KEY,
},
},
dodoc: {
runOnCompile: true,
......
......@@ -70,7 +70,7 @@
"@ethersproject/providers": "^5.6.0",
"@nomiclabs/ethereumjs-vm": "^4.2.2",
"@nomiclabs/hardhat-ethers": "^2.0.2",
"@nomiclabs/hardhat-etherscan": "^2.1.6",
"@nomiclabs/hardhat-etherscan": "^3.0.3",
"@nomiclabs/hardhat-waffle": "^2.0.1",
"@openzeppelin/contracts": "4.3.2",
"@openzeppelin/contracts-upgradeable": "4.3.2",
......
......@@ -2520,18 +2520,18 @@
resolved "https://registry.yarnpkg.com/@nomiclabs/hardhat-ethers/-/hardhat-ethers-2.0.2.tgz#c472abcba0c5185aaa4ad4070146e95213c68511"
integrity sha512-6quxWe8wwS4X5v3Au8q1jOvXYEPkS1Fh+cME5u6AwNdnI4uERvPlVjlgRWzpnb+Rrt1l/cEqiNRH9GlsBMSDQg==
"@nomiclabs/hardhat-etherscan@^2.1.6":
version "2.1.6"
resolved "https://registry.yarnpkg.com/@nomiclabs/hardhat-etherscan/-/hardhat-etherscan-2.1.6.tgz#8d1502f42adc6f7b8ef16fb917c0b5a8780cb83a"
integrity sha512-gCvT5fj8GbXS9+ACS3BzrX0pzYHHZqAHCb+NcipOkl2cy48FakUXlzrCf4P4sTH+Y7W10OgT62ezD1sJ+/NikQ==
"@nomiclabs/hardhat-etherscan@^3.0.3":
version "3.0.3"
resolved "https://registry.yarnpkg.com/@nomiclabs/hardhat-etherscan/-/hardhat-etherscan-3.0.3.tgz#ca54a03351f3de41f9f5240e37bea9d64fa24e64"
integrity sha512-OfNtUKc/ZwzivmZnnpwWREfaYncXteKHskn3yDnz+fPBZ6wfM4GR+d5RwjREzYFWE+o5iR9ruXhWw/8fejWM9g==
dependencies:
"@ethersproject/abi" "^5.1.2"
"@ethersproject/address" "^5.0.2"
cbor "^5.0.2"
debug "^4.1.1"
fs-extra "^7.0.1"
node-fetch "^2.6.0"
semver "^6.3.0"
undici "^4.14.1"
"@nomiclabs/hardhat-waffle@^2.0.1":
version "2.0.1"
......@@ -11566,7 +11566,7 @@ node-fetch@2.6.1:
resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.6.1.tgz#045bd323631f76ed2e2b55573394416b639a0052"
integrity sha512-V4aYg89jEoVRxRb2fJdAg8FHvI7cEyYdVAh94HH0UIK8oJxUfkjlDQN9RbMx+bEjP7+ggMiFRprSti032Oipxw==
node-fetch@^2.6.0, node-fetch@^2.6.1, node-fetch@^2.6.7:
node-fetch@^2.6.1, node-fetch@^2.6.7:
version "2.6.7"
resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.6.7.tgz#24de9fba827e3b4ae44dc8b20256a379160052ad"
integrity sha512-ZjMPFEfVx5j+y2yF35Kzx5sF7kDzxuDj6ziH4FFbOp87zKDZNx8yExJIb05OGF4Nlt9IHFIMBkRl41VdvcNdbQ==
......@@ -15430,11 +15430,6 @@ typedarray@^0.0.6:
resolved "https://registry.yarnpkg.com/typedarray/-/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777"
integrity sha1-hnrHTjhkGHsdPUfZlqeOxciDB3c=
typescript@^4.3.4, typescript@^4.3.5, typescript@^4.6.2:
version "4.6.2"
resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.6.2.tgz#fe12d2727b708f4eef40f51598b3398baa9611d4"
integrity sha512-HM/hFigTBHZhLXshn9sN37H085+hQGeJHJ/X7LpBWLID/fbc2acUMfU+lGD98X81sKP+pFa9f0DZmCwB9GnbAg==
typedoc@^0.22.13:
version "0.22.13"
resolved "https://registry.yarnpkg.com/typedoc/-/typedoc-0.22.13.tgz#d061f8f0fb7c9d686e48814f245bddeea4564e66"
......@@ -15446,6 +15441,11 @@ typedoc@^0.22.13:
minimatch "^5.0.1"
shiki "^0.10.1"
typescript@^4.3.4, typescript@^4.3.5, typescript@^4.6.2:
version "4.6.2"
resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.6.2.tgz#fe12d2727b708f4eef40f51598b3398baa9611d4"
integrity sha512-HM/hFigTBHZhLXshn9sN37H085+hQGeJHJ/X7LpBWLID/fbc2acUMfU+lGD98X81sKP+pFa9f0DZmCwB9GnbAg==
typewise-core@^1.2, typewise-core@^1.2.0:
version "1.2.0"
resolved "https://registry.yarnpkg.com/typewise-core/-/typewise-core-1.2.0.tgz#97eb91805c7f55d2f941748fa50d315d991ef195"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment