aboutsummaryrefslogtreecommitdiffstats
path: root/rpc/args.go
diff options
context:
space:
mode:
Diffstat (limited to 'rpc/args.go')
-rw-r--r--rpc/args.go9
1 files changed, 2 insertions, 7 deletions
diff --git a/rpc/args.go b/rpc/args.go
index 459c6546b..96188d02e 100644
--- a/rpc/args.go
+++ b/rpc/args.go
@@ -649,18 +649,13 @@ func (args *FilterStringArgs) UnmarshalJSON(b []byte) (err error) {
if !ok {
return NewInvalidTypeError("filter", "not a string")
}
- args.Word = argstr
-
- return nil
-}
-
-func (args *FilterStringArgs) requirements() error {
- switch args.Word {
+ switch argstr {
case "latest", "pending":
break
default:
return NewValidationError("Word", "Must be `latest` or `pending`")
}
+ args.Word = argstr
return nil
}