Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix:fix panic when handlePassedV1Beta1Proposal #755

Open
wants to merge 1 commit into
base: cosmos/v0.47.x
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions modules/gov/utils_proposal.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import (
"fmt"
"strings"

"github.com/cosmos/cosmos-sdk/codec"
sdk "github.com/cosmos/cosmos-sdk/types"
govtypesv1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1"
govtypesv1beta1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1"
Expand Down Expand Up @@ -286,8 +285,7 @@ func getParamChangeSubspace(msg sdk.Msg) (string, bool) {
func (m *Module) handlePassedV1Beta1Proposal(proposal *govtypesv1.Proposal, msg *govtypesv1.MsgExecLegacyContent, height int64) error {
// Unpack proposal
var content govtypesv1beta1.Content
var protoCodec codec.ProtoCodec
err := protoCodec.UnpackAny(msg.Content, &content)
err := m.cdc.UnpackAny(msg.Content, &content)
if err != nil {
return fmt.Errorf("error while handling ParamChangeProposal: %s", err)
}
Expand Down
Loading