add isDepositProcessed
MODIFY
src/root/DepositManager.ts
src/root/DepositManager.ts
@@ -46,13 +46,17 @@ export default class DepositManager extends ContractsBase {
const depositId = '0x' + data.substring(data.length - 64)
deposits.push({
depositId,
- isProcessed: await this.childChainContract.methods.deposits(depositId).call(),
+ isProcessed: await this.isDepositProcessed(depositId),
})
})
}
return { receipt: depositReceipt, deposits }
}
+ isDepositProcessed(depositId) {
+ return this.childChainContract.methods.deposits(depositId).call()
+ }
+
async approveERC20(token: address, amount: BN | string, options?: SendOptions) {
const txObject = this.getERC20TokenContract(token, true).methods.approve(
this.depositManagerContract.options.address,

add isDepositProcessed