This commit is contained in:
cebgcontract 2022-12-21 16:08:05 +08:00
parent c1589f5b89
commit 14e92fd53f

View File

@ -38,7 +38,7 @@ export class JCStandard {
.buy721NFT(addresses, values, signature)
.estimateGas({ gas: SAMPLE_GAS });
} catch (err) {}
gas = gas ? gas * 1.1 : SAMPLE_GAS;
gas = gas ? (gas * 1.1) | 1 : SAMPLE_GAS;
}
//@ts-ignore
if (jc.wallet.isInternal) {
@ -92,7 +92,7 @@ export class JCStandard {
.buy1155NFT(addresses, values, ids, amounts, signature)
.estimateGas({ gas: SAMPLE_GAS });
} catch (err) {}
gas = gas ? gas * 1.1 : SAMPLE_GAS;
gas = gas ? (gas * 1.1) | 1 : SAMPLE_GAS;
}
//@ts-ignore
@ -146,7 +146,7 @@ export class JCStandard {
.evolve721NFT(nftAddress, tokenIds, startTime, nonce, signature)
.estimateGas({ gas: SAMPLE_GAS });
} catch (err) {}
gas = gas ? gas * 1.1 : SAMPLE_GAS;
gas = gas ? (gas * 1.1) | 1 : SAMPLE_GAS;
}
//@ts-ignore
@ -198,7 +198,7 @@ export class JCStandard {
.evolveChip(tokenIds, startTime, nonce, signature)
.estimateGas({ gas: SAMPLE_GAS });
} catch (err) {}
gas = gas ? gas * 1.1 : SAMPLE_GAS;
gas = gas ? (gas * 1.1) | 1 : SAMPLE_GAS;
}
//@ts-ignore
@ -252,7 +252,7 @@ export class JCStandard {
.mintShardBatchUser(tokenIds, amounts, startTime, nonce, signature)
.estimateGas({ gas: SAMPLE_GAS });
} catch (err) {}
gas = gas ? gas * 1.1 : SAMPLE_GAS;
gas = gas ? (gas * 1.1) | 1 : SAMPLE_GAS;
}
//@ts-ignore
@ -324,7 +324,7 @@ export class JCStandard {
)
.estimateGas({ gas: SAMPLE_GAS });
} catch (err) {}
gas = gas ? gas * 1.1 : SAMPLE_GAS;
gas = gas ? (gas * 1.1) | 1 : SAMPLE_GAS;
}
//@ts-ignore
@ -403,8 +403,8 @@ export class JCStandard {
.estimateGas({ gas: SAMPLE_GAS });
} catch (err) {}
if (!gas) {
gas1 = gas1 ? gas1 * 1.1 : SAMPLE_GAS;
gas0 = gas0 ? gas0 * 1.1 : SAMPLE_GAS;
gas1 = gas1 ? (gas1 * 1.1) | 1 : SAMPLE_GAS;
gas0 = gas0 ? (gas0 * 1.1) | 1 : SAMPLE_GAS;
gas = gas0 + gas1;
} else {
gas0 = gas - gas1;
@ -473,7 +473,7 @@ export class JCStandard {
} catch (err) {
console.log(err);
}
gas = gas ? gas * 1.1 : SAMPLE_GAS;
gas = gas ? (gas * 1.1) | 1 : SAMPLE_GAS;
}
if (jc.wallet.isInternal) {