Skip to content

Commit

Permalink
Merge pull request codegram#13 from gucki/master
Browse files Browse the repository at this point in the history
fix for codegram#11
  • Loading branch information
Josep M. Bach committed Jul 27, 2011
2 parents a9df07b + 0d67680 commit 64aeafd
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/rack/webconsole/assets.rb
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ def call(env)
# Inject the html, css and js code to the view
response_body.gsub!('</body>', "#{code}</body>")

headers['Content-Length'] = (response_body.length + 2).to_s
headers['Content-Length'] = response_body.bytesize.to_s

[status, headers, [response_body]]
end
Expand Down
2 changes: 1 addition & 1 deletion lib/rack/webconsole/repl.rb
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ def call(env)
response_body = {:result => result}.to_json
headers = {}
headers['Content-Type'] = 'application/json'
headers['Content-Length'] = response_body.length.to_s
headers['Content-Length'] = response_body.bytesize.to_s
[200, headers, [response_body]]
end

Expand Down

0 comments on commit 64aeafd

Please sign in to comment.