[英]Can I change smart contract which is already deployed on BSC?
Everyone.每个人。 I have a token contract that has a mint function.
我有一个代币合约,上面有铸币厂 function。 It has only burn function and it deployed to the mainnet.
它只烧毁了 function 并部署到了主网上。 I am going to add the mint function to the token?
我要将薄荷 function 添加到令牌中吗? It is available.
它是可用的。 Here is the current token contract, contract MyToken is ERC20, ERC20Detailed, ERC20Burnable {
这里是当前代币合约,合约MyToken是ERC20,ERC20Detailed,ERC20Burnable {
constructor () public ERC20Detailed("MyToken", "MY", 18) {
_mint(msg.sender, 15000000 * (10 ** uint256(decimals())));
}
}
Above contract used openzeppelin.上面的合约使用了 openzeppelin。 I will be very thankful if you teach me how to change this contract.
如果您能教我如何更改这份合同,我将不胜感激。
You cannot update it unless you have used a proxy or otherwise coded in that you can update it.除非您使用了代理或以其他方式编码,否则您无法更新它。 You'll have to redeploy.
你必须重新部署。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.