Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
duck59uet authored Dec 7, 2022
1 parent 9adc390 commit 4f09530
Showing 1 changed file with 1 addition and 13 deletions.
14 changes: 1 addition & 13 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,18 +70,7 @@ Beside, we will use CosmJs version larger than 0.29.4. The aurajs lib simply use
When tx return success result, you can use fee to call to `allowedAddress`.

### Instantiate contract example use fee has granted
From version 0.29.4, StdFee interface has granter properties.

```ts
export interface StdFee {
readonly amount: readonly Coin[];
readonly gas: string;
/** The granter address that is used for paying with feegrants */
readonly granter?: string;
/** The fee payer address. The payer must have signed the transaction. */
readonly payer?: string;
}
```
From version 0.29.4, `makeAuthInfoBytes` function has 2 more parameters: feeGranter, feePayer. If you want granter pay fee for tx, just input here.

Just define your custum StdFee and broadcast tx. Example:

Expand All @@ -102,7 +91,6 @@ Just define your custum StdFee and broadcast tx. Example:
const fee: StdFee = {
amount: coins(5000, "uaura"),
gas: "890000",
granter: 'granterAddress'
};

const chainId = await client.getChainId();
Expand Down

0 comments on commit 4f09530

Please sign in to comment.