Files
openzeppelin-contracts/contracts/mocks/docs/MyContractOwnable.sol
github-actions 9efe429a18 Update docs
2023-10-05 01:42:23 +00:00

18 lines
402 B
Solidity

// SPDX-License-Identifier: MIT
pragma solidity ^0.8.20;
import {Ownable} from "../../access/Ownable.sol";
contract MyContract is Ownable {
constructor(address initialOwner) Ownable(initialOwner) {}
function normalThing() public {
// anyone can call this normalThing()
}
function specialThing() public onlyOwner {
// only the owner can call specialThing()!
}
}