Skip to content

Commit

Permalink
fix query
Browse files Browse the repository at this point in the history
  • Loading branch information
jayy04 committed Dec 11, 2024
1 parent 4beed22 commit 00e8976
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
6 changes: 5 additions & 1 deletion protocol/x/accountplus/client/cli/query.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import (
"github.com/spf13/cobra"

"github.com/cosmos/cosmos-sdk/client"
"github.com/cosmos/cosmos-sdk/client/flags"
"github.com/dydxprotocol/v4-chain/protocol/x/accountplus/types"
)

Expand Down Expand Up @@ -51,14 +52,15 @@ func CmdQueryParam() *cobra.Command {
return clientCtx.PrintProto(res)
},
}
flags.AddQueryFlagsToCmd(cmd)
return cmd
}

func CmdQueryGetAuthenticator() *cobra.Command {
cmd := &cobra.Command{
Use: "get-authenticator [account] [authenticator_id]",
Short: "Get authenticator",
Args: cobra.ExactArgs(3),
Args: cobra.ExactArgs(2),
RunE: func(cmd *cobra.Command, args []string) error {
clientCtx, err := client.GetClientQueryContext(cmd)
if err != nil {
Expand All @@ -82,6 +84,7 @@ func CmdQueryGetAuthenticator() *cobra.Command {
return clientCtx.PrintProto(res)
},
}
flags.AddQueryFlagsToCmd(cmd)
return cmd
}

Expand All @@ -108,5 +111,6 @@ func CmdQueryGetAllAuthenticators() *cobra.Command {
return clientCtx.PrintProto(res)
},
}
flags.AddQueryFlagsToCmd(cmd)
return cmd
}
2 changes: 1 addition & 1 deletion protocol/x/accountplus/client/cli/tx.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ func GetTxCmd() *cobra.Command {

func CmdAddAuthenticator() *cobra.Command {
cmd := &cobra.Command{
Use: "add-authenticator account authenticator_type data",
Use: "add-authenticator [account] [authenticator_type] [data]",
Short: "Registers an authenticator",
Args: cobra.ExactArgs(3),
RunE: func(cmd *cobra.Command, args []string) error {
Expand Down

0 comments on commit 00e8976

Please sign in to comment.