Giveth / vaultcontroller

Vault Architecture
GNU General Public License v3.0
0 stars 3 forks source link

Add recipient can be added/removed from a removed spender #36

Closed adria0 closed 7 years ago

adria0 commented 7 years ago
vaultController.authorizeSpender("SPENDER", spender, 10, 2, 3, 7, 6 );
vaultController.removeAuthorizedSpender(spender);
vaultController.authorizeRecipient(spender,recipient,"RECIPIENT"); // should fail

and

vc.authorizeSpender("SPENDER", spender, 10, 2, 3, 7, 6 );
vc.authorizeRecipient(spender,recipient,"RECIPIENT");
vc.removeAuthorizedSpender(spender);
vc.removeAuthorizedRecipient(spender,recipient) // should fail
jbaylina commented 7 years ago

https://github.com/Giveth/vaultcontroller/blob/master/contracts/VaultController.sol#L593

This will throw because it will not find the spender in the index.

adria0 commented 7 years ago

Ok. Error was generated by #31 now closed.