In blockchain you must be able to stop the chaos. Sometimes you could not think of everything, and at some point the mechanisms you built in fail. One mechanism is still left then: a switch that turns things on and off.
This slide was shown at Devconnect 2025, held in Buenos Aires, Argentina.
Pausable in OpenZeppelin
That is what the Pausable mechanism and interface in the OpenZeppelin library are for. On the slide above it is added to an ERC20 token through ERC20Pausable. Only the holder of PAUSER_ROLE can pause and unpause the contract, and functions marked whenNotPaused do not run while it is paused:
I strongly recommend Pausable to every smart contract developer. Never forget about it: when everything else has already failed, it is the one thing that lets you stop the contract.
Two tools from the AllYouNeedIsNFT marketplace: a service that scores a new NFT image against indexed collections, and an editor that assembles collages from one artist's assets.
Across the systems I build I pay close attention to user roles and permissions. Here is the hierarchical, adaptable model I reuse, and how a team brainstorm picks the right fit each time.
Open for contract collaboration
I am available for contract-based collaboration. If you have an interesting project idea, schedule a call via Calendly.