Skip to content

Commit

Permalink
fix: add check for nil on raw.NodeLocation
Browse files Browse the repository at this point in the history
  • Loading branch information
0xalank committed Jul 30, 2024
1 parent 1c28ec3 commit 6d9e8ac
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions quai/filters/api.go
Original file line number Diff line number Diff line change
Expand Up @@ -563,6 +563,10 @@ func (args *FilterCriteria) UnmarshalJSON(data []byte) error {
}
}

if raw.NodeLocation == nil {
return fmt.Errorf("NodeLocation is required but was not provided")
}

args.Addresses = []common.Address{}

if raw.Addresses != nil {
Expand Down

0 comments on commit 6d9e8ac

Please sign in to comment.