From ac4ac3661f4cb2784db3a77b7c52c5de74419ffc Mon Sep 17 00:00:00 2001 From: Michael Oberegger Date: Tue, 31 Mar 2026 23:08:31 -0400 Subject: [PATCH] Save on extra to_s when reading response body --- lib/openapi_first/response_parser.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/openapi_first/response_parser.rb b/lib/openapi_first/response_parser.rb index d406ccde..90666173 100644 --- a/lib/openapi_first/response_parser.rb +++ b/lib/openapi_first/response_parser.rb @@ -25,7 +25,7 @@ def read_body(rack_response) buffered_body = +'' if rack_response.body.respond_to?(:each) - rack_response.body.each { |chunk| buffered_body.to_s << chunk } + rack_response.body.each { |chunk| buffered_body << chunk } return buffered_body end rack_response.body