Skip to content

Commit

Permalink
add nil custom get signer fxn for msgEthTx
Browse files Browse the repository at this point in the history
  • Loading branch information
yan-soon committed Dec 10, 2023
1 parent 531367b commit 9ef9e4e
Showing 1 changed file with 2 additions and 16 deletions.
18 changes: 2 additions & 16 deletions app/params/encoding.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ import (
"github.com/cosmos/cosmos-sdk/codec/address"
"github.com/cosmos/cosmos-sdk/codec/types"
sdk "github.com/cosmos/cosmos-sdk/types"
"github.com/cosmos/cosmos-sdk/types/module"
"github.com/cosmos/cosmos-sdk/x/auth/tx"
"github.com/cosmos/gogoproto/proto"
evmtypes "github.com/evmos/ethermint/x/evm/types"
Expand All @@ -23,7 +22,7 @@ type EncodingConfig struct {
Amino *codec.LegacyAmino
}

func MakeEncodingConfig(modules ...module.AppModuleBasic) EncodingConfig {
func MakeEncodingConfig() EncodingConfig {
amino := codec.NewLegacyAmino()
options := types.InterfaceRegistryOptions{
ProtoFiles: proto.HybridResolver,
Expand All @@ -42,20 +41,7 @@ func MakeEncodingConfig(modules ...module.AppModuleBasic) EncodingConfig {
protoreflect.FullName(sdk.MsgTypeURL((*evmtypes.MsgEthereumTx)(nil))),
test,
)
interfaceRegistry, _ := types.NewInterfaceRegistryWithOptions(
// todo: should panic here?
types.InterfaceRegistryOptions{
ProtoFiles: proto.HybridResolver,
SigningOptions: signing.Options{
AddressCodec: address.Bech32Codec{
Bech32Prefix: "tswth",
},
ValidatorAddressCodec: address.Bech32Codec{
Bech32Prefix: "tswthvaloper",
},
},
},
)
interfaceRegistry, _ := types.NewInterfaceRegistryWithOptions(options)
codec := codec.NewProtoCodec(interfaceRegistry)
txCfg := tx.NewTxConfig(codec, tx.DefaultSignModes)

Expand Down

0 comments on commit 9ef9e4e

Please sign in to comment.