diff --git a/lib/mini_profiler.rb b/lib/mini_profiler.rb index cccbce90..edbe10ac 100644 --- a/lib/mini_profiler.rb +++ b/lib/mini_profiler.rb @@ -329,7 +329,7 @@ def call(env) ) end elsif path == '/rack-mini-profiler/requests' - status, headers, body = [200, { 'Content-Type' => 'text/html' }, [blank_page_html]] + status, headers, body = [200, { 'Content-Type' => 'text/html' }, [blank_page_html.dup]] # important to dup here! else status, headers, body = @app.call(env) end diff --git a/spec/integration/middleware_spec.rb b/spec/integration/middleware_spec.rb index acb6f98a..65ba066f 100644 --- a/spec/integration/middleware_spec.rb +++ b/spec/integration/middleware_spec.rb @@ -27,7 +27,7 @@ def app get '/rack-mini-profiler/requests', {}, 'HTTP_ACCEPT_ENCODING' => 'gzip, compress' expect(last_response.body).to include('