Overview
ThePausable mixin provides a trading “kill switch” functionality. The primary entry points to the CTF Exchange are decorated with the notPaused modifier, allowing trading to be paused if needed. This provides an emergency stop mechanism for the exchange.
Source: src/exchange/mixins/Pausable.sol
State Variables
paused
true, functions decorated with notPaused will revert.
Modifiers
notPaused
paused state variable is true. Applied to trading functions to prevent execution when the exchange is paused.
Reverts: Paused() if trading is currently paused.
Functions
_pauseTrading
paused state variable to true, which causes all functions decorated with notPaused to revert.
Emits
TradingPaused(msg.sender)
_unpauseTrading
paused state variable to false. This unpauses trading by allowing the notPaused modifier to pass.
Emits
TradingUnpaused(msg.sender)
Events
TradingPaused
Parameters
pauser(address): The address that paused trading
TradingUnpaused
Parameters
pauser(address): The address that unpaused trading