From df3837cdf2bedd7f80e5774f862cb743fafb89fe Mon Sep 17 00:00:00 2001 From: Samyak Jain <34437877+KaymasJain@users.noreply.github.com> Date: Mon, 18 Apr 2022 19:16:23 +0400 Subject: [PATCH] minor name update on function --- contracts/infiniteProxy/proxy.sol | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/contracts/infiniteProxy/proxy.sol b/contracts/infiniteProxy/proxy.sol index 5df63f3..c544292 100644 --- a/contracts/infiniteProxy/proxy.sol +++ b/contracts/infiniteProxy/proxy.sol @@ -35,7 +35,7 @@ contract Internals is Events { /** * @dev Returns the storage slot which stores the sigs array set for the implementation. */ - function _getSlotImplSigsSlot(address implementation_) + function _getImplSigsSlot(address implementation_) internal pure returns (bytes32) @@ -49,7 +49,7 @@ contract Internals is Events { /** * @dev Returns the storage slot which stores the implementation address for the function sig. */ - function _getSlotSigsImplSlot(bytes4 sig_) internal pure returns (bytes32) { + function _getSigsImplSlot(bytes4 sig_) internal pure returns (bytes32) { return keccak256(abi.encode("eip1967.proxy.implementation", sig_)); } @@ -87,11 +87,11 @@ contract Internals is Events { bytes4[] memory sigs_ ) internal { require(sigs_.length != 0, "no-sigs"); - bytes32 slot_ = _getSlotImplSigsSlot(implementation_); + bytes32 slot_ = _getImplSigsSlot(implementation_); bytes4[] memory sigsCheck_ = getSigsSlot(slot_).value; require(sigsCheck_.length == 0, "implementation-already-exist"); for (uint256 i = 0; i < sigs_.length; i++) { - bytes32 sigSlot_ = _getSlotSigsImplSlot(sigs_[i]); + bytes32 sigSlot_ = _getSigsImplSlot(sigs_[i]); require( getAddressSlot(sigSlot_).value == address(0), "sig-already-exist" @@ -106,11 +106,11 @@ contract Internals is Events { * @dev Removes implementation and the mappings corresponding to it. */ function _removeImplementationSigs(address implementation_) internal { - bytes32 slot_ = _getSlotImplSigsSlot(implementation_); + bytes32 slot_ = _getImplSigsSlot(implementation_); bytes4[] memory sigs_ = getSigsSlot(slot_).value; require(sigs_.length != 0, "implementation-not-exist"); for (uint256 i = 0; i < sigs_.length; i++) { - bytes32 sigSlot_ = _getSlotSigsImplSlot(sigs_[i]); + bytes32 sigSlot_ = _getSigsImplSlot(sigs_[i]); delete getAddressSlot(sigSlot_).value; } delete getSigsSlot(slot_).value; @@ -125,7 +125,7 @@ contract Internals is Events { view returns (bytes4[] memory) { - bytes32 slot_ = _getSlotImplSigsSlot(implementation_); + bytes32 slot_ = _getImplSigsSlot(implementation_); return getSigsSlot(slot_).value; } @@ -137,7 +137,7 @@ contract Internals is Events { view returns (address implementation_) { - bytes32 slot_ = _getSlotSigsImplSlot(sig_); + bytes32 slot_ = _getSigsImplSlot(sig_); return getAddressSlot(slot_).value; }