mirror of
https://github.com/tendermint/tendermint.git
synced 2026-02-05 19:40:44 +00:00
remove multi element qualifier from handler slice check
This commit is contained in:
@@ -43,7 +43,7 @@ func Fuzz(data []byte) int {
|
||||
return 1
|
||||
}
|
||||
|
||||
if outputJSONIsMultiElementSlice(blob) {
|
||||
if outputJSONIsSlice(blob) {
|
||||
recv := []types.RPCResponse{}
|
||||
if err := json.Unmarshal(blob, &recv); err != nil {
|
||||
panic(err)
|
||||
@@ -57,8 +57,8 @@ func Fuzz(data []byte) int {
|
||||
return 1
|
||||
}
|
||||
|
||||
func outputJSONIsMultiElementSlice(input []byte) bool {
|
||||
func outputJSONIsSlice(input []byte) bool {
|
||||
slice := []interface{}{}
|
||||
err := json.Unmarshal(input, &slice)
|
||||
return err == nil && len(slice) > 1
|
||||
return err == nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user