From 494114c1ceef28bbada3a2ab4119fb2b7c9de1bf Mon Sep 17 00:00:00 2001 From: mpoke Date: Thu, 16 Mar 2023 19:34:11 +0100 Subject: [PATCH] fix SlashLogKey bug --- x/ccv/provider/types/keys.go | 2 +- x/ccv/provider/types/keys_test.go | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/x/ccv/provider/types/keys.go b/x/ccv/provider/types/keys.go index acb73aea29..07773a91f3 100644 --- a/x/ccv/provider/types/keys.go +++ b/x/ccv/provider/types/keys.go @@ -446,5 +446,5 @@ func ParseChainIdAndConsAddrKey(prefix byte, bz []byte) (string, sdk.ConsAddress // SlashLogKey returns the key to a validator's slash log func SlashLogKey(providerAddr ProviderConsAddress) []byte { - return append([]byte{SlashAcksBytePrefix}, providerAddr.ToSdkConsAddr().Bytes()...) + return append([]byte{SlashLogBytePrefix}, providerAddr.ToSdkConsAddr().Bytes()...) } diff --git a/x/ccv/provider/types/keys_test.go b/x/ccv/provider/types/keys_test.go index 5570c024c0..1ebc7213fe 100644 --- a/x/ccv/provider/types/keys_test.go +++ b/x/ccv/provider/types/keys_test.go @@ -66,6 +66,7 @@ func getSingleByteKeys() [][]byte { keys[i], i = []byte{providertypes.ThrottledPacketDataSizeBytePrefix}, i+1 keys[i], i = []byte{providertypes.ThrottledPacketDataBytePrefix}, i+1 keys[i], i = []byte{providertypes.GlobalSlashEntryBytePrefix}, i+1 + keys[i], i = []byte{providertypes.SlashLogBytePrefix}, i+1 return keys[:i] }