-
Notifications
You must be signed in to change notification settings - Fork 987
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #124 from gnosis/issue-123
Emit event when master copy changes
- Loading branch information
Showing
2 changed files
with
32 additions
and
9 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,9 @@ import "./SelfAuthorized.sol"; | |
/// This contract is tightly coupled to our proxy contract (see `proxies/Proxy.sol`) | ||
/// @author Richard Meissner - <[email protected]> | ||
contract MasterCopy is SelfAuthorized { | ||
|
||
event ChangedMasterCopy(address masterCopy); | ||
|
||
// masterCopy always needs to be first declared variable, to ensure that it is at the same location as in the Proxy contract. | ||
// It should also always be ensured that the address is stored alone (uses a full word) | ||
address masterCopy; | ||
|
@@ -19,5 +22,6 @@ contract MasterCopy is SelfAuthorized { | |
// Master copy address cannot be null. | ||
require(_masterCopy != address(0), "Invalid master copy address provided"); | ||
masterCopy = _masterCopy; | ||
emit ChangedMasterCopy(_masterCopy); | ||
} | ||
} |
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