123456789101112131415161718192021 |
- // SPDX-License-Identifier: MIT
- pragma solidity ^0.8.0;
- import "../CountersImpl.sol";
- import "../../proxy/utils/UUPSUpgradeable.sol";
- contract UUPSUpgradeableMock is CountersImpl, UUPSUpgradeable {
- // Not having any checks in this function is dangerous! Do not do this outside tests!
- function _authorizeUpgrade(address) internal override {}
- }
- contract UUPSUpgradeableUnsafeMock is UUPSUpgradeableMock {
- function upgradeTo(address newImplementation) external override {
- ERC1967Upgrade._upgradeToAndCall(newImplementation, bytes(""), false);
- }
- function upgradeToAndCall(address newImplementation, bytes memory data) external payable override {
- ERC1967Upgrade._upgradeToAndCall(newImplementation, data, false);
- }
- }
|