diff --git a/lib/puma/server.rb b/lib/puma/server.rb index 17290117..4c102b3e 100644 --- a/lib/puma/server.rb +++ b/lib/puma/server.rb @@ -522,7 +522,9 @@ module Puma raise "No REQUEST PATH" unless env[REQUEST_PATH] - env[QUERY_STRING] = uri.query + # A nil env value will cause a LintError (and fatal errors elsewhere), + # so only set the env value if there actually is a value. + env[QUERY_STRING] = uri.query if uri.query end env[PATH_INFO] = env[REQUEST_PATH]