Permalink
Browse files

Use Rack::Utils.bytesize when calculating content-length of exception…

… pages. [#4727 state:resolved]

Signed-off-by: José Valim <jose.valim@gmail.com>
  • Loading branch information...
1 parent 667522c commit bb6cd6d3ec02996c7dd11a4bb96381da18b7de8a @tarsolya tarsolya committed with josevalim May 29, 2010
Showing with 1 addition and 1 deletion.
  1. +1 −1 actionpack/lib/action_dispatch/middleware/show_exceptions.rb
@@ -122,7 +122,7 @@ def status_code(exception)
end
def render(status, body)
- [status, {'Content-Type' => 'text/html', 'Content-Length' => body.length.to_s}, [body]]
+ [status, {'Content-Type' => 'text/html', 'Content-Length' => body.bytesize.to_s}, [body]]
end
def public_path

0 comments on commit bb6cd6d

Please sign in to comment.