OpenST / mosaic-contracts

Mosaic-0: Gateways and anchors on top of Ethereum to scale DApps
https://discuss.openst.org/c/mosaic
MIT License
114 stars 31 forks source link

OSTComposer::removeStakerProxy should call on StakerProxy::selfDestruct #771

Closed pgev closed 5 years ago

pgev commented 5 years ago

Currently, to remove/destroy StakerProxy owner should call StakerProxy::selfDestruct.

Instead, OSTComposer::removeStakerProxy can assume msg.sender is an owner, retrieve StakerProxy for that owner, call StakerProxy::selfDestruct on retrieved staker proxy (modifier for StakerProxy::selfDestruct should become onlyComposer).