Commit f0ed649d by Arseniy Klempner

Add release method to Stoppable. Create StoppableMock

parent 5eea131f
...@@ -21,4 +21,9 @@ contract Stoppable { ...@@ -21,4 +21,9 @@ contract Stoppable {
stopped = true; stopped = true;
} }
function release() external onlyInEmergency {
if (msg.sender != curator) throw;
stopped = false;
}
} }
pragma solidity ^0.4.0;
import '../Stoppable.sol';
// mock class using Stoppable
contract StoppableMock is Stoppable {
bool public drasticMeasureTaken;
uint public count = 0;
function normalProcess() external stopInEmergency {
count++;
}
function drasticMeasure() external onlyInEmergency {
drasticMeasureTaken = true;
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment