Skip to content

Commit

Permalink
fix rebasing issues
Browse files Browse the repository at this point in the history
  • Loading branch information
Amxx committed Mar 10, 2021
1 parent 2c74b5b commit 9e729df
Show file tree
Hide file tree
Showing 4 changed files with 1 addition and 80 deletions.
24 changes: 0 additions & 24 deletions contracts/proxy/ERC1967/ERC1967Proxy.sol
Original file line number Diff line number Diff line change
Expand Up @@ -30,28 +30,4 @@ contract ERC1967Proxy is Proxy, ERC1967Upgrade {
function _implementation() internal view virtual override returns (address impl) {
return ERC1967Storage._getImplementation();
}

/**
* @dev Upgrades the proxy to a new implementation.
*
* Emits an {Upgraded} event.
*/
function _upgradeTo(address newImplementation) internal virtual {
_setImplementation(newImplementation);
emit Upgraded(newImplementation);
}

/**
* @dev Stores a new address in the EIP1967 implementation slot.
*/
function _setImplementation(address newImplementation) private {
require(Address.isContract(newImplementation), "ERC1967Proxy: new implementation is not a contract");

bytes32 slot = _IMPLEMENTATION_SLOT;

// solhint-disable-next-line no-inline-assembly
assembly {
sstore(slot, newImplementation)
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ contract TransparentUpgradeableProxy is IERC1967Upgradeable, ERC1967Proxy {
* @dev Initializes an upgradeable proxy managed by `_admin`, backed by the implementation at `_logic`, and
* optionally initialized with `_data` as explained in {UpgradeableProxy-constructor}.
*/
constructor(address _logic, address admin_, bytes memory _data) payable UUPSProxy(_logic, _data) {
constructor(address _logic, address admin_, bytes memory _data) payable ERC1967Proxy(_logic, _data) {
assert(_ADMIN_SLOT == bytes32(uint256(keccak256("eip1967.proxy.admin")) - 1));
_changeAdmin(admin_);
}
Expand Down
42 changes: 0 additions & 42 deletions contracts/proxy/uups/UUPSProxy.sol

This file was deleted.

13 changes: 0 additions & 13 deletions test/proxy/uups/UUPSProxy.test.js

This file was deleted.

0 comments on commit 9e729df

Please sign in to comment.