diff --git a/lib/bugsnag/middleware/rack_request.rb b/lib/bugsnag/middleware/rack_request.rb index 387e5df4..63bff078 100644 --- a/lib/bugsnag/middleware/rack_request.rb +++ b/lib/bugsnag/middleware/rack_request.rb @@ -109,7 +109,7 @@ def add_request_body(report, request, env) body = parsed_request_body(request, env) # this request may not have a body - return unless body.is_a?(Hash) && !body.empty? + return if body.nil? report.add_metadata(:request, :body, body) end