Skip to content

Commit

Permalink
fix(assets): remove StakerExoCoreAddr
Browse files Browse the repository at this point in the history
  • Loading branch information
MaxMustermann2 committed May 30, 2024
1 parent 64287b2 commit 7348e76
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 50 deletions.
5 changes: 0 additions & 5 deletions proto/exocore/assets/v1/query.proto
Original file line number Diff line number Diff line change
Expand Up @@ -155,10 +155,5 @@ service Query {
option (cosmos.query.v1.module_query_safe) = true;
option (google.api.http).get = "/exocore/assets/v1/QueStakerSpecifiedAssetAmount";
}
// // StakerExCoreAddr queries the staker exocore address.
// rpc QueStakerExoCoreAddr(QueryStakerExCoreAddr) returns (QueryStakerExCoreAddrResponse) {
// option (cosmos.query.v1.module_query_safe) = true;
// option (google.api.http).get = "/exocore/assets/v1/QueStakerExoCoreAddr/{staker}";
// }
}

35 changes: 0 additions & 35 deletions x/assets/client/cli/query.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ func GetQueryCmd() *cobra.Command {
QueStakerSpecifiedAssetAmount(),
QueOperatorAssetInfos(),
QueOperatorSpecifiedAssetAmount(),
// QueStakerExoCoreAddr(),
)
return cmd
}
Expand Down Expand Up @@ -331,37 +330,3 @@ func QueOperatorSpecifiedAssetAmount() *cobra.Command {
flags.AddQueryFlagsToCmd(cmd)
return cmd
}

// // QueStakerExoCoreAddr queries staker ExoCore address
// func QueStakerExoCoreAddr() *cobra.Command {
// cmd := &cobra.Command{
// Use: "QueStakerExoCoreAddr stakerID",
// Short: "Get staker ExoCore address",
// Long: "Get staker ExoCore address",
// Args: cobra.ExactArgs(1),
// RunE: func(cmd *cobra.Command, args []string) error {
// clientCtx, err := client.GetClientQueryContext(cmd)
// if err != nil {
// return err
// }

// stakerID := args[0]
// if _, _, err := types.ValidateID(stakerID, false, false); err != nil {
// return errorsmod.Wrap(types.ErrInvalidCliCmdArg, err.Error())
// }

// queryClient := types.NewQueryClient(clientCtx)
// req := &types.QueryStakerExCoreAddr{
// Staker: strings.ToLower(stakerID),
// }
// res, err := queryClient.QueStakerExoCoreAddr(context.Background(), req)
// if err != nil {
// return err
// }
// return clientCtx.PrintProto(res)
// },
// }

// flags.AddQueryFlagsToCmd(cmd)
// return cmd
// }
10 changes: 0 additions & 10 deletions x/assets/keeper/grpc_query.go
Original file line number Diff line number Diff line change
Expand Up @@ -93,13 +93,3 @@ func (k Keeper) QueOperatorSpecifiedAssetAmount(ctx context.Context, req *assets
}
return k.GetOperatorSpecifiedAssetInfo(c, addr, req.AssetID)
}

// // QueStakerExoCoreAddr outdated,will be deprecated
// func (k Keeper) QueStakerExoCoreAddr(ctx context.Context, req *assetstype.QueryStakerExCoreAddr) (*assetstype.QueryStakerExCoreAddrResponse, error) {
// c := sdk.UnwrapSDKContext(ctx)
// exoCoreAddr, err := k.GetStakerExoCoreAddr(c, req.Staker)
// if err != nil {
// return nil, err
// }
// return &assetstype.QueryStakerExCoreAddrResponse{ExoCoreAddr: exoCoreAddr}, nil
// }

0 comments on commit 7348e76

Please sign in to comment.