0

I have deployed my contract to mainnet,All thing was fine but after I tried to call initialize method I got error and I think proxies not initiated

How can I do now? I lost some Ether and nothing worth that

pragma solidity ^0.6.0;


import '@openzeppelin/contracts-ethereum-package/contracts/Initializable.sol';
import '@openzeppelin/contracts-ethereum-package/contracts/presets/ERC20PresetMinterPauser.sol';
import '@openzeppelin/contracts-ethereum-package/contracts/access/Ownable.sol';
contract Token is Initializable, ERC20PresetMinterPauserUpgradeSafe   {
  function initialize() public initializer {
    ERC20PresetMinterPauserUpgradeSafe.initialize("Cryptomind", "CR");
      _setupDecimals(8);
  }


}

? Pick a network mainnet
? Pick a contract to deploy Token 
√ Contract Token deployed
All implementations have been deployed
? Call a function to initialize the instance after creating it? Yes
? Select which function * initialize()
**× Setting everything up to create contract instances
insufficient funds for gas * price + value**

oz call
? Pick a network mainnet
A contract address must be specified.
  • I don't know what you are trying to achieve, but there is no proxy here. – Adam Boudjemaa Sep 16 '20 at 22:22
  • You need to deploy a factory, then link your contract (library) to this factory and then you can issue proxies. Check EIP 1167, may I ask why you need a proxy here? – Adam Boudjemaa Sep 16 '20 at 22:24
0

Finally,I found my answer here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.