|
@@ -113,14 +113,12 @@ export abstract class BaseClient {
|
|
|
|
|
|
async checkBalance() {
|
|
|
const balances = await this.lcd.bank.balance(this.key.accAddress)
|
|
|
- console.log(JSON.stringify(balances))
|
|
|
return balances[0].toArray()
|
|
|
}
|
|
|
|
|
|
async funded() {
|
|
|
const tokens = await this.checkBalance()
|
|
|
const uinit = tokens.filter(token => token.denom === 'uinit')[0]
|
|
|
- console.log(uinit.amount)
|
|
|
return Number(uinit.amount) > 0
|
|
|
}
|
|
|
|
|
@@ -175,7 +173,6 @@ export abstract class BaseClient {
|
|
|
}
|
|
|
async getEthAmount() {
|
|
|
const tokens = await this.checkBalance()
|
|
|
- console.log(tokens)
|
|
|
try {
|
|
|
const usdc = tokens.filter(token => token.denom === 'ueth')[0]
|
|
|
return usdc.amount
|
|
@@ -267,7 +264,6 @@ export abstract class BaseClient {
|
|
|
feeDenoms: ['uinit'],
|
|
|
})
|
|
|
const broadcast = await this.lcd.tx.broadcast(signed)
|
|
|
- console.log(broadcast)
|
|
|
}
|
|
|
async bridge2Ai(amount: number) {
|
|
|
const size = bcs
|