From b171601678d7ef85957110e13f52a6543d951ba7 Mon Sep 17 00:00:00 2001 From: Aleksey Bykhun Date: Thu, 13 Oct 2022 18:40:02 +0200 Subject: [PATCH 1/2] Update web3.js --- src/mint/web3.js | 17 ++++------------- 1 file changed, 4 insertions(+), 13 deletions(-) diff --git a/src/mint/web3.js b/src/mint/web3.js index c1e4d49..54d1b15 100644 --- a/src/mint/web3.js +++ b/src/mint/web3.js @@ -21,7 +21,7 @@ const getMethodWithCustomName = (methodName) => { } const getMintTx = ({ numberOfTokens }) => { - return NFTContract.methods.mint(); + return NFTContract.methods.whitelistmint(); } const getDefaultMintPrice = () => { @@ -40,7 +40,7 @@ const getDefaultMintPrice = () => { } export const getMintPrice = async () => { - return 1e18.toString() + return 1e17.toString() } export const getMintedNumber = async () => { @@ -69,20 +69,11 @@ export const getMaxSupply = async () => { } export const getDefaultMaxTokensPerMint = () => { - return window.MAX_PER_MINT ?? 10 + return 1 } export const getMaxTokensPerMint = async () => { - if (NFTContract?.methods?.maxPerMint) { - return Number(await NFTContract.methods.maxPerMint().call()) - } - if (NFTContract?.methods?.maxMintAmount) { - return Number(await NFTContract.methods.maxMintAmount().call()) - } - if (NFTContract?.methods?.MAX_TOKENS_PER_MINT) { - return Number(await NFTContract.methods.MAX_TOKENS_PER_MINT().call()) - } - return getDefaultMaxTokensPerMint() + return 1 } export const mint = async (nTokens) => { From 34a418f95da78aead186df0153f8341e7c715e88 Mon Sep 17 00:00:00 2001 From: Aleksey Bykhun Date: Thu, 13 Oct 2022 19:03:42 +0200 Subject: [PATCH 2/2] Update web3.js --- src/mint/web3.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mint/web3.js b/src/mint/web3.js index 54d1b15..06402b7 100644 --- a/src/mint/web3.js +++ b/src/mint/web3.js @@ -21,7 +21,7 @@ const getMethodWithCustomName = (methodName) => { } const getMintTx = ({ numberOfTokens }) => { - return NFTContract.methods.whitelistmint(); + return NFTContract.methods.whitelistMint(); } const getDefaultMintPrice = () => {