should revert when update contributor account with address(0)
This commit is contained in:
parent
19ca89e1eb
commit
8927c55661
@ -54,6 +54,7 @@ contract Contributor is AragonApp {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function updateContributorAccount(uint32 id, address oldAccount, address newAccount) public auth(MANAGE_CONTRIBUTORS_ROLE) {
|
function updateContributorAccount(uint32 id, address oldAccount, address newAccount) public auth(MANAGE_CONTRIBUTORS_ROLE) {
|
||||||
|
require(newAccount != address(0), "invalid new account address");
|
||||||
require(getContributorAddressById(id) == oldAccount, "contributor does not exist");
|
require(getContributorAddressById(id) == oldAccount, "contributor does not exist");
|
||||||
|
|
||||||
contributorIds[oldAccount] = 0;
|
contributorIds[oldAccount] = 0;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user