diff --git a/resolver.go b/resolver.go index 69450b63..d16f40c0 100644 --- a/resolver.go +++ b/resolver.go @@ -275,7 +275,7 @@ func setFields(ctx *hcontext, req *http.Request, input reflect.Value, t reflect. location = locationQuery if v := req.URL.Query().Get(name); v != "" { pv = v - } else if req.URL.Query().Has(name) && f.Type.Kind() == reflect.Bool { + } else if f.Type.Kind() == reflect.Bool { // name has no associated value, but exists in the map of QueryParams. This is a boolean value _, vok := req.URL.Query()[name] if vok {