-
Notifications
You must be signed in to change notification settings - Fork 88
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
91dd5c0
commit 082508e
Showing
19 changed files
with
2,618 additions
and
2,196 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,18 +3,46 @@ | |
"version": "1.0.0", | ||
"description": "", | ||
"dependencies": { | ||
"@sandbox-smart-contracts/dependency-metatx": "^0.0.2" | ||
"@sandbox-smart-contracts/dependency-metatx": "^0.0.2", | ||
"web3-core-helpers": "^1.10.0", | ||
"web3-core-promievent": "^1.10.0", | ||
"web3-eth-abi": "^4.1.1" | ||
}, | ||
"devDependencies": { | ||
"@daonomic/tests-common": "^0.2.2", | ||
"@nomiclabs/hardhat-truffle5": "^2.0.7", | ||
"@nomiclabs/hardhat-web3": "^2.0.0", | ||
"@openzeppelin/contracts": "4.9.3", | ||
"@openzeppelin/contracts-upgradeable": "4.9.3", | ||
"@ethereumjs/block": "^3.5.1", | ||
"@ethereumjs/common": "^2.5.0", | ||
"@ethereumjs/tx": "^3.3.2", | ||
"@ethersproject/units": "^5.7.0", | ||
"@ethersproject/wallet": "^5.0.5", | ||
"@nomicfoundation/hardhat-chai-matchers": "^1.0.6", | ||
"@nomicfoundation/hardhat-network-helpers": "^1.0.9", | ||
"@nomiclabs/hardhat-ethers": "npm:[email protected]", | ||
"@nomiclabs/hardhat-etherscan": "^3.0.3", | ||
"@openzeppelin/contracts": "^4.9.3", | ||
"@openzeppelin/contracts-upgradeable": "^4.9.3", | ||
"@types/chai": "^4.2.11", | ||
"hardhat": "^2.17.2", | ||
"@types/mocha": "^8.0.2", | ||
"@types/node": "^14.10.2", | ||
"@typescript-eslint/eslint-plugin": "^4.6.0", | ||
"@typescript-eslint/parser": "^4.6.0", | ||
"chai": "^4.2.0", | ||
"cross-env": "^7.0.2", | ||
"dotenv": "^8.2.0", | ||
"dotenv-cli": "^4.0.0", | ||
"eslint": "^7.7.0", | ||
"eslint-config-prettier": "^6.11.0", | ||
"eslint-plugin-mocha": "^8.0.0", | ||
"ethereumjs-util": "^7.1.3", | ||
"ethers": "^5.7.2", | ||
"hardhat": "~2.15.0", | ||
"hardhat-contract-sizer": "^2.0.3", | ||
"hardhat-deploy": "^0.10.5", | ||
"hardhat-gas-reporter": "^1.0.4", | ||
"prettier": "2.0.5", | ||
"prettier-plugin-solidity": "1.0.0-beta.11", | ||
"readline": "^1.3.0", | ||
"solhint-plugin-prettier": "^0.0.5", | ||
"solidity-coverage": "0.8.2", | ||
"ts-node": "^10.9.1", | ||
"typescript": "^4.0.5", | ||
"web3": "^1.10.2" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
//SPDX-License-Identifier: MIT | ||
// solhint-disable-next-line compiler-version | ||
pragma solidity 0.8.19; | ||
|
||
import {ERC1967UpgradeUpgradeable} from "@openzeppelin/contracts-upgradeable/proxy/ERC1967/ERC1967UpgradeUpgradeable.sol"; | ||
|
||
/// @dev just for testing don't use this code on production !!!! | ||
contract FakeProxy is ERC1967UpgradeUpgradeable { | ||
constructor(address newImplementation) { | ||
_upgradeTo(newImplementation); | ||
} | ||
|
||
function _delegate(address implementation) internal virtual { | ||
// solhint-disable-next-line no-inline-assembly | ||
assembly { | ||
calldatacopy(0, 0, calldatasize()) | ||
let result := delegatecall(gas(), implementation, 0, calldatasize(), 0, 0) | ||
returndatacopy(0, 0, returndatasize()) | ||
switch result | ||
case 0 { | ||
revert(0, returndatasize()) | ||
} | ||
default { | ||
return(0, returndatasize()) | ||
} | ||
} | ||
} | ||
|
||
fallback() external payable { | ||
_delegate(_getImplementation()); | ||
} | ||
|
||
receive() external payable { | ||
_delegate(_getImplementation()); | ||
} | ||
} |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.