made acceptOwnership() throw when not newOwner
This commit is contained in:
parent
9cc092d2cd
commit
a4793fb44d
|
@ -34,7 +34,7 @@ contract Owned {
|
||||||
|
|
||||||
/// @notice `newOwner` can accept ownership over this contract
|
/// @notice `newOwner` can accept ownership over this contract
|
||||||
function acceptOwnership() {
|
function acceptOwnership() {
|
||||||
if (msg.sender == newOwner) {
|
require(msg.sender == newOwner) {
|
||||||
owner = newOwner;
|
owner = newOwner;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue