From 23178ecef0807b53a924d679e8c2d6ed04484d12 Mon Sep 17 00:00:00 2001 From: Reece Williams <31943163+Reecepbcups@users.noreply.github.com> Date: Wed, 20 Sep 2023 00:46:28 -0500 Subject: [PATCH] feat: Add GetNode() helper (#789) --- chain/cosmos/cosmos_chain.go | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/chain/cosmos/cosmos_chain.go b/chain/cosmos/cosmos_chain.go index f781bd032..71f88bb4e 100644 --- a/chain/cosmos/cosmos_chain.go +++ b/chain/cosmos/cosmos_chain.go @@ -194,6 +194,10 @@ func (c *CosmosChain) getFullNode() *ChainNode { return c.Validators[0] } +func (c *CosmosChain) GetNode() *ChainNode { + return c.Validators[0] +} + // Exec implements ibc.Chain. func (c *CosmosChain) Exec(ctx context.Context, cmd []string, env []string) (stdout, stderr []byte, err error) { return c.getFullNode().Exec(ctx, cmd, env) @@ -390,8 +394,8 @@ func (c *CosmosChain) PushNewWasmClientProposal(ctx context.Context, keyName str return tx, "", err } message := wasmtypes.MsgStoreCode{ - Signer: types.MustBech32ifyAddressBytes(c.cfg.Bech32Prefix, authtypes.NewModuleAddress(govtypes.ModuleName)), - WasmByteCode: content, + Signer: types.MustBech32ifyAddressBytes(c.cfg.Bech32Prefix, authtypes.NewModuleAddress(govtypes.ModuleName)), + WasmByteCode: content, } msg, err := c.cfg.EncodingConfig.Codec.MarshalInterfaceJSON(&message) if err != nil {