fixed function revert if executed

This commit is contained in:
Michael M
2021-11-08 17:51:28 +02:00
committed by Aleksander Kryukov
parent 2761ec0b66
commit 53d4006806

View File

@ -61,7 +61,13 @@ invariant cannotSetIfCanceled(uint256 pId)
* No functions should be allowed to run after a job is deemed as executed
*/
invariant cannotSetIfExecuted(uint256 pId)
isExecuted(pId) => lastReverted == true
isExecuted(pId) => lastReverted == true
{
preserved execute(address[] targets, uint256[] values, bytes[] calldatas, bytes32 descriptionHash) with (env e)
{
require(isExecuted(pId));
}
}