From 318bc23431cc264b68c54619fb15084f478f4261 Mon Sep 17 00:00:00 2001 From: PleBea Date: Thu, 26 Sep 2024 01:29:30 +0900 Subject: [PATCH] feat: Add waitForDeployment() method after approving token transfer --- src/modules/blockchain/blockchain.service.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/modules/blockchain/blockchain.service.ts b/src/modules/blockchain/blockchain.service.ts index 67e2488..af0fbf0 100644 --- a/src/modules/blockchain/blockchain.service.ts +++ b/src/modules/blockchain/blockchain.service.ts @@ -75,7 +75,7 @@ export class BlockchainService { await erc20.approve(this.deployer.address, ethers.parseUnits(amount.toString(), 18)); - await erc20.wait(); + await erc20.waitForDeployment(); await erc20.transfer(to, ethers.parseUnits(amount.toString(), 18), { gasLimit: 100000,