diff options
Diffstat (limited to 'eth/filters/api.go')
-rw-r--r-- | eth/filters/api.go | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/eth/filters/api.go b/eth/filters/api.go index 54336aaf9..9e95ebd83 100644 --- a/eth/filters/api.go +++ b/eth/filters/api.go @@ -331,7 +331,7 @@ func (args *NewFilterArgs) UnmarshalJSON(data []byte) error { if decAddr, err := hex.DecodeString(strAddr); err == nil { addresses = append(addresses, common.BytesToAddress(decAddr)) } else { - fmt.Errorf("invalid address given") + return fmt.Errorf("invalid address given") } } else { return fmt.Errorf("invalid address on index %d", i) @@ -344,10 +344,10 @@ func (args *NewFilterArgs) UnmarshalJSON(data []byte) error { if decAddr, err := hex.DecodeString(singleAddr); err == nil { addresses = append(addresses, common.BytesToAddress(decAddr)) } else { - fmt.Errorf("invalid address given") + return fmt.Errorf("invalid address given") } } else { - errors.New("invalid address(es) given") + return errors.New("invalid address(es) given") } args.Addresses = addresses } @@ -394,7 +394,7 @@ func (args *NewFilterArgs) UnmarshalJSON(data []byte) error { parsedTopics[i] = []common.Hash{t} } } else { - fmt.Errorf("topic[%d][%d] not a string", i, j) + return fmt.Errorf("topic[%d][%d] not a string", i, j) } } } else { |