Skip to content

Commit

Permalink
chore: include authority query cmd
Browse files Browse the repository at this point in the history
  • Loading branch information
johnletey committed Sep 17, 2024
1 parent 0d72544 commit 211fb26
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions x/florin/client/cli/query.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ func GetQueryCmd() *cobra.Command {

cmd.AddCommand(GetBlacklistQueryCmd())

cmd.AddCommand(QueryAuthority())
cmd.AddCommand(QueryAllowedDenoms())
cmd.AddCommand(QueryOwners())
cmd.AddCommand(QuerySystems())
Expand All @@ -47,6 +48,29 @@ func GetQueryCmd() *cobra.Command {
return cmd
}

func QueryAuthority() *cobra.Command {
cmd := &cobra.Command{
Use: "authority",
Short: "Query the authority address of this module",
Args: cobra.NoArgs,
RunE: func(cmd *cobra.Command, args []string) error {
clientCtx := client.GetClientContextFromCmd(cmd)
queryClient := types.NewQueryClient(clientCtx)

res, err := queryClient.Authority(context.Background(), &types.QueryAuthority{})
if err != nil {
return err
}

return clientCtx.PrintProto(res)
},
}

flags.AddQueryFlagsToCmd(cmd)

return cmd
}

func QueryAllowedDenoms() *cobra.Command {
cmd := &cobra.Command{
Use: "allowed-denoms",
Expand Down

0 comments on commit 211fb26

Please sign in to comment.