Skip to content

Commit

Permalink
add helper functions to retrieve configured keypair info
Browse files Browse the repository at this point in the history
  • Loading branch information
bonedaddy committed Jul 17, 2023
1 parent 84c02e0 commit 46940e3
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -103,3 +103,13 @@ func (c *Client) BroadcastTx(ctx context.Context, msgs ...sdk.Msg) (string, erro
}
}
}

// Returns the address of the key used for transaction signing
func (c *Client) FromAddress() string {
return c.cctx.FromAddress.String()
}

// Returns the name of the key used for transaction signing
func (c *Client) FromName() string {
return c.cctx.GetFromName()
}

0 comments on commit 46940e3

Please sign in to comment.