Skip to content

Commit

Permalink
♻️ Align with OZ Implementation
Browse files Browse the repository at this point in the history
Signed-off-by: Pascal Marco Caversaccio <[email protected]>
  • Loading branch information
pcaversaccio committed Jan 21, 2025
1 parent 8db992a commit 84bc7ef
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/snekmate/utils/pausable.vy
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ def _pause():
@notice This is an `internal` function without access
restriction.
"""
self._assert_unpaused()
self._require_not_paused()
self.paused = True
log Paused(account=msg.sender)

Expand All @@ -88,21 +88,21 @@ def _unpause():
@notice This is an `internal` function without access
restriction.
"""
self._assert_paused()
self._require_paused()
self.paused = False
log Unpaused(account=msg.sender)


@internal
def _assert_unpaused():
def _require_not_paused():
"""
@dev Throws if the contract is paused.
"""
assert not self.paused, "pausable: contract is paused"


@internal
def _assert_paused():
def _require_paused():
"""
@dev Throws if the contract is not paused.
"""
Expand Down

0 comments on commit 84bc7ef

Please sign in to comment.