diff --git a/x/slashing/keeper/keeper.go b/x/slashing/keeper/keeper.go index 1e622f56eb..0c1182da9f 100644 --- a/x/slashing/keeper/keeper.go +++ b/x/slashing/keeper/keeper.go @@ -45,7 +45,7 @@ func NewKeeper(cdc codec.BinaryCodec, legacyAmino *codec.LegacyAmino, storeServi sb, types.ValidatorSigningInfoKeyPrefix, "validator_signing_info", - sdk.ConsAddressKey, + sdk.LengthPrefixedAddressKey(sdk.ConsAddressKey), // nolint: staticcheck // sdk.LengthPrefixedAddressKey is needed to retain state compatibility codec.CollValue[types.ValidatorSigningInfo](cdc), ), } diff --git a/x/slashing/types/signing_info.go b/x/slashing/types/signing_info.go index 8e9519d51d..18443311aa 100644 --- a/x/slashing/types/signing_info.go +++ b/x/slashing/types/signing_info.go @@ -3,7 +3,6 @@ package types import ( "time" - "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" ) @@ -21,9 +20,3 @@ func NewValidatorSigningInfo( MissedBlocksCounter: missedBlocksCounter, } } - -// UnmarshalValSigningInfo unmarshals a validator signing info from a store value -func UnmarshalValSigningInfo(cdc codec.Codec, value []byte) (signingInfo ValidatorSigningInfo, err error) { - err = cdc.Unmarshal(value, &signingInfo) - return signingInfo, err -}