11// SPDX-License-Identifier: MIT
22pragma solidity ^ 0.8.20 ;
33
4- import {LibOwnableRoles } from "@diamond/libraries/LibOwnableRoles .sol " ;
4+ import {OwnableRolesLib } from "@diamond/libraries/OwnableRolesLib .sol " ;
55
66/// @title OwnableRolesFacet
77/// @notice Simple single owner and multiroles authorization mixin.
@@ -16,7 +16,7 @@ import {LibOwnableRoles} from "@diamond/libraries/LibOwnableRoles.sol";
1616/// [EIP-173](https://eips.ethereum.org/EIPS/eip-173) for compatibility,
1717/// the nomenclature for the 2-step ownership handover may be unique to this codebase.
1818contract OwnableRolesFacet {
19- using LibOwnableRoles for * ;
19+ using OwnableRolesLib for * ;
2020
2121 /*´:°•.°+.*•´.*:˚.°*.˚•´.°:°•.°•.*•´.*:˚.°*.˚•´.°:°•.°+.*•´.*:*/
2222 /* PUBLIC UPDATE FUNCTIONS */
@@ -29,18 +29,18 @@ contract OwnableRolesFacet {
2929
3030 /// @dev Allows the owner to renounce their ownership.
3131 function renounceOwnership () public onlyOwner {
32- LibOwnableRoles ._renounceOwnership ();
32+ OwnableRolesLib ._renounceOwnership ();
3333 }
3434
3535 /// @dev Request a two-step ownership handover to the caller.
3636 /// The request will automatically expire in 48 hours (172800 seconds) by default.
3737 function requestOwnershipHandover () public {
38- LibOwnableRoles ._requestOwnershipHandover ();
38+ OwnableRolesLib ._requestOwnershipHandover ();
3939 }
4040
4141 /// @dev Cancels the two-step ownership handover to the caller, if any.
4242 function cancelOwnershipHandover () public {
43- LibOwnableRoles ._cancelOwnershipHandover ();
43+ OwnableRolesLib ._cancelOwnershipHandover ();
4444 }
4545
4646 /// @dev Allows the owner to complete the two-step ownership handover to `pendingOwner`.
@@ -73,7 +73,7 @@ contract OwnableRolesFacet {
7373
7474 /// @dev Returns the owner of the contract.
7575 function owner () public view returns (address ) {
76- return LibOwnableRoles ._owner ();
76+ return OwnableRolesLib ._owner ();
7777 }
7878
7979 /// @dev Returns the expiry timestamp for the two-step ownership handover to `pendingOwner`.
@@ -116,27 +116,27 @@ contract OwnableRolesFacet {
116116
117117 /// @dev Marks a function as only callable by the owner.
118118 modifier onlyOwner () {
119- LibOwnableRoles ._checkOwner ();
119+ OwnableRolesLib ._checkOwner ();
120120 _;
121121 }
122122
123123 /// @dev Marks a function as only callable by an account with `roles`.
124124 modifier onlyRoles (uint256 _roles ) {
125- LibOwnableRoles ._checkRoles (_roles);
125+ OwnableRolesLib ._checkRoles (_roles);
126126 _;
127127 }
128128
129129 /// @dev Marks a function as only callable by the owner or by an account
130130 /// with `roles`. Checks for ownership first, then lazily checks for roles.
131131 modifier onlyOwnerOrRoles (uint256 _roles ) {
132- LibOwnableRoles ._checkOwnerOrRoles (_roles);
132+ OwnableRolesLib ._checkOwnerOrRoles (_roles);
133133 _;
134134 }
135135
136136 /// @dev Marks a function as only callable by an account with `roles` or the owner.
137137 /// Checks for roles first, then lazily checks for ownership.
138138 modifier onlyRolesOrOwner (uint256 _roles ) {
139- LibOwnableRoles ._checkRolesOrOwner (_roles);
139+ OwnableRolesLib ._checkRolesOrOwner (_roles);
140140 _;
141141 }
142142}
0 commit comments