We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 85312a0 commit 2c4ac9dCopy full SHA for 2c4ac9d
contracts/governance/Governed.sol
@@ -51,15 +51,16 @@ contract Governed {
51
* This function must called by the pending governor.
52
*/
53
function acceptOwnership() external {
54
+ address _pendingGovernor = pendingGovernor;
55
require(
- pendingGovernor != address(0) && msg.sender == pendingGovernor,
56
+ _pendingGovernor != address(0) && msg.sender == _pendingGovernor,
57
"Caller must be pending governor"
58
);
59
60
address oldGovernor = governor;
- address oldPendingGovernor = pendingGovernor;
61
+ address oldPendingGovernor = _pendingGovernor;
62
- governor = pendingGovernor;
63
+ governor = _pendingGovernor;
64
pendingGovernor = address(0);
65
66
emit NewOwnership(oldGovernor, governor);
0 commit comments