Skip to content

Commit

Permalink
Fix golangci
Browse files Browse the repository at this point in the history
  • Loading branch information
luckychess committed Feb 3, 2025
1 parent d91f461 commit 51e6b6c
Show file tree
Hide file tree
Showing 5 changed files with 4 additions and 12 deletions.
5 changes: 0 additions & 5 deletions x/gmp/client/cli/tx.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,6 @@ var (
DefaultRelativePacketTimeoutTimestamp = (time.Duration(10) * time.Minute).Nanoseconds()
)

const (
flagPacketTimeoutTimestamp = "packet-timeout-timestamp"
listSeparator = ","
)

// GetTxCmd returns the transaction commands for this module
func GetTxCmd() *cobra.Command {
cmd := &cobra.Command{
Expand Down
3 changes: 1 addition & 2 deletions x/gmp/keeper/msg_server_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import (
"context"
"testing"

sdk "github.com/cosmos/cosmos-sdk/types"
keepertest "github.com/sagaxyz/ssc/testutil/keeper"
"github.com/sagaxyz/ssc/x/gmp/keeper"
"github.com/sagaxyz/ssc/x/gmp/types"
Expand All @@ -13,7 +12,7 @@ import (

func setupMsgServer(t testing.TB) (types.MsgServer, context.Context) {
k, ctx := keepertest.GmpKeeper(t)
return keeper.NewMsgServerImpl(*k), sdk.WrapSDKContext(ctx)
return keeper.NewMsgServerImpl(*k), ctx
}

func TestMsgServer(t *testing.T) {
Expand Down
4 changes: 1 addition & 3 deletions x/gmp/keeper/query_params_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,19 +3,17 @@ package keeper_test
import (
"testing"

sdk "github.com/cosmos/cosmos-sdk/types"
testkeeper "github.com/sagaxyz/ssc/testutil/keeper"
"github.com/sagaxyz/ssc/x/gmp/types"
"github.com/stretchr/testify/require"
)

func TestParamsQuery(t *testing.T) {
keeper, ctx := testkeeper.GmpKeeper(t)
wctx := sdk.WrapSDKContext(ctx)
params := types.DefaultParams()
keeper.SetParams(ctx, params)

response, err := keeper.Params(wctx, &types.QueryParamsRequest{})
response, err := keeper.Params(ctx, &types.QueryParamsRequest{})
require.NoError(t, err)
require.Equal(t, &types.QueryParamsResponse{Params: params}, response)
}
2 changes: 1 addition & 1 deletion x/gmp/module.go
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ func (AppModuleBasic) ValidateGenesis(cdc codec.JSONCodec, config client.TxEncod

// RegisterGRPCGatewayRoutes registers the gRPC Gateway routes for the module
func (AppModuleBasic) RegisterGRPCGatewayRoutes(clientCtx client.Context, mux *runtime.ServeMux) {
types.RegisterQueryHandlerClient(context.Background(), mux, types.NewQueryClient(clientCtx))
types.RegisterQueryHandlerClient(context.Background(), mux, types.NewQueryClient(clientCtx)) //nolint:errcheck

Check warning

Code scanning / gosec

Errors unhandled Warning

Errors unhandled
}

// GetTxCmd returns the root Tx command for the module. The subcommands of this root command are used by end-users to generate new transactions containing messages defined in the module
Expand Down
2 changes: 1 addition & 1 deletion x/gmp/module_simulation.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ func (AppModule) GenerateGenesisState(simState *module.SimulationState) {
// func (am AppModule) RegisterStoreDecoder(_ sdk.StoreDecoderRegistry) {}

// ProposalContents doesn't return any content functions for governance proposals.
func (AppModule) ProposalContents(_ module.SimulationState) []simtypes.WeightedProposalContent {
func (AppModule) ProposalContents(_ module.SimulationState) []simtypes.WeightedProposalMsg {
return nil
}

Expand Down

0 comments on commit 51e6b6c

Please sign in to comment.