Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
  • Loading branch information
Amxx authored Jun 20, 2023
1 parent 8e6d187 commit 830920a
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions contracts/governance/extensions/GovernorTimelockControl.sol
Original file line number Diff line number Diff line change
Expand Up @@ -125,10 +125,10 @@ abstract contract GovernorTimelockControl is IGovernorTimelock, Governor {
bytes[] memory calldatas,
bytes32 descriptionHash
) internal virtual override {
// cleanup for refund
delete _timelockIds[proposalId];
// execute
_timelock.executeBatch{value: msg.value}(targets, values, calldatas, 0, descriptionHash);
// cleanup for refund
delete _timelockIds[proposalId];
}

/**
Expand All @@ -148,10 +148,10 @@ abstract contract GovernorTimelockControl is IGovernorTimelock, Governor {
bytes32 timelockId = _timelockIds[proposalId];

if (timelockId != 0) {
// cleanup
delete _timelockIds[proposalId];
// cancel
_timelock.cancel(timelockId);
// cleanup
delete _timelockIds[proposalId];
}

return proposalId;
Expand Down

0 comments on commit 830920a

Please sign in to comment.