In tableCodec.go, line 146, the comment is suggesting to use errInvalidRecordKey.GenWithStack whereas the function is decoding index prefix key. Might be better to consider changing this into using errInvalidIndexKey.GenWithStack.
func DecodeIndexKeyPrefix(key kv.Key) (tableID int64, indexID int64, indexValues []byte, err error) {
...
* 3. errInvalidRecordKey.GenWithStack is a useful function to generate invalid record key errors.
...
}
To
func DecodeIndexKeyPrefix(key kv.Key) (tableID int64, indexID int64, indexValues []byte, err error) {
...
* 3. errInvalidIndexKey.GenWithStack is a useful function to generate invalid record key errors.
...
}
In
tableCodec.go
, line 146, the comment is suggesting to useerrInvalidRecordKey.GenWithStack
whereas the function is decoding index prefix key. Might be better to consider changing this into usingerrInvalidIndexKey.GenWithStack
.To