Allow deployer to set a migration-done flag
All checks were successful
continuous-integration/drone/pr Build is passing
continuous-integration/drone/push Build is passing

* Save deployer's address on contract initialization
* Add modifier for requiring tx sender to be deployer
* Add migrationDone flag and function to set it to finished status
This commit is contained in:
Râu Cao
2022-08-23 12:15:16 +01:00
parent 0fc4eed09a
commit de1574155c
5 changed files with 69 additions and 12 deletions

18
package-lock.json generated
View File

@@ -1216,6 +1216,12 @@
"dependencies": {
"@types/sinon-chai": "^3.2.3",
"@types/web3": "1.0.19"
},
"peerDependencies": {
"@nomiclabs/hardhat-ethers": "^2.0.0",
"ethereum-waffle": "^3.2.0",
"ethers": "^5.0.0",
"hardhat": "^2.0.0"
}
},
"node_modules/@openzeppelin/contracts-upgradeable": {
@@ -1708,9 +1714,9 @@
}
},
"node_modules/@types/sinon": {
"version": "10.0.11",
"resolved": "https://registry.npmjs.org/@types/sinon/-/sinon-10.0.11.tgz",
"integrity": "sha512-dmZsHlBsKUtBpHriNjlK0ndlvEh8dcb9uV9Afsbt89QIyydpC7NcR+nWlAhASfy3GHnxTl4FX/aKE7XZUt/B4g==",
"version": "10.0.13",
"resolved": "https://registry.npmjs.org/@types/sinon/-/sinon-10.0.13.tgz",
"integrity": "sha512-UVjDqJblVNQYvVNUsj0PuYYw0ELRmgt1Nt5Vk0pT5f16ROGfcKJY8o1HVuMOJOpD727RrGB9EGvoaTQE5tgxZQ==",
"dev": true,
"dependencies": {
"@types/sinonjs__fake-timers": "*"
@@ -21394,9 +21400,9 @@
}
},
"@types/sinon": {
"version": "10.0.11",
"resolved": "https://registry.npmjs.org/@types/sinon/-/sinon-10.0.11.tgz",
"integrity": "sha512-dmZsHlBsKUtBpHriNjlK0ndlvEh8dcb9uV9Afsbt89QIyydpC7NcR+nWlAhASfy3GHnxTl4FX/aKE7XZUt/B4g==",
"version": "10.0.13",
"resolved": "https://registry.npmjs.org/@types/sinon/-/sinon-10.0.13.tgz",
"integrity": "sha512-UVjDqJblVNQYvVNUsj0PuYYw0ELRmgt1Nt5Vk0pT5f16ROGfcKJY8o1HVuMOJOpD727RrGB9EGvoaTQE5tgxZQ==",
"dev": true,
"requires": {
"@types/sinonjs__fake-timers": "*"