faucet: Update for removed default fees
This commit is contained in:
parent
c2384cc0ce
commit
c06dd0c0ce
@ -5,6 +5,7 @@ import {
|
||||
} from "@cosmjs/launchpad";
|
||||
import {
|
||||
assertIsBroadcastTxSuccess as assertIsBroadcastTxSuccessStargate,
|
||||
calculateFee,
|
||||
SigningStargateClient,
|
||||
StargateClient,
|
||||
} from "@cosmjs/stargate";
|
||||
@ -88,7 +89,8 @@ export class Faucet {
|
||||
const result = await client.sendTokens(job.recipient, [job.amount], constants.memo);
|
||||
return assertIsBroadcastTxSuccessLaunchpad(result);
|
||||
}
|
||||
const result = await client.sendTokens(job.sender, job.recipient, [job.amount], constants.memo);
|
||||
const fee = calculateFee(constants.gasLimits.send, constants.gasPrice);
|
||||
const result = await client.sendTokens(job.sender, job.recipient, [job.amount], fee, constants.memo);
|
||||
assertIsBroadcastTxSuccessStargate(result);
|
||||
}
|
||||
|
||||
|
||||
@ -43,10 +43,7 @@ export async function createClients(
|
||||
> => [
|
||||
senderAddress,
|
||||
isOfflineDirectSigner(wallet)
|
||||
? await SigningStargateClient.connectWithSigner(apiUrl, wallet, {
|
||||
gasLimits: constants.gasLimits,
|
||||
gasPrice: constants.gasPrice,
|
||||
})
|
||||
? await SigningStargateClient.connectWithSigner(apiUrl, wallet)
|
||||
: new SigningCosmosClient(apiUrl, senderAddress, wallet, constants.gasPrice, constants.gasLimits),
|
||||
],
|
||||
),
|
||||
|
||||
Loading…
Reference in New Issue
Block a user