From b0698606231c1765022636c90c75a0276a9b5e31 Mon Sep 17 00:00:00 2001 From: Julien Robert Date: Tue, 10 Oct 2023 17:29:46 +0200 Subject: [PATCH] fix: textual options wiring --- cmd/minid/cmd/root.go | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/cmd/minid/cmd/root.go b/cmd/minid/cmd/root.go index a4109f0..309c93c 100644 --- a/cmd/minid/cmd/root.go +++ b/cmd/minid/cmd/root.go @@ -92,16 +92,10 @@ func NewRootCmd() *cobra.Command { return err } - // This needs to go after ReadFromClientConfig, as that function - // sets the RPC client needed for SIGN_MODE_TEXTUAL. - enabledSignModes := append(tx.DefaultSignModes, signing.SignMode_SIGN_MODE_TEXTUAL) - txConfigWithTextual, err := tx.NewTxConfigWithOptions( - codec.NewProtoCodec(clientCtx.InterfaceRegistry), - tx.ConfigOptions{ - EnabledSignModes: enabledSignModes, - TextualCoinMetadataQueryFn: txmodule.NewGRPCCoinMetadataQueryFn(clientCtx), - }, - ) + // This needs to go after ReadFromClientConfig, as that function ets the RPC client needed for SIGN_MODE_TEXTUAL. + txConfigOpts.EnabledSignModes = append(tx.DefaultSignModes, signing.SignMode_SIGN_MODE_TEXTUAL) + txConfigOpts.TextualCoinMetadataQueryFn = txmodule.NewGRPCCoinMetadataQueryFn(clientCtx) + txConfigWithTextual, err := tx.NewTxConfigWithOptions(codec.NewProtoCodec(clientCtx.InterfaceRegistry), txConfigOpts) if err != nil { return err }