aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorStormwind <stormwind@stormwinds-page.de>2012-11-23 18:06:53 +0100
committerStormwind <stormwind@stormwinds-page.de>2012-11-23 18:06:53 +0100
commita2e6c299cd15b8335441e3b5ba07fe95256f3a2d (patch)
treeb42ef45756a008c37171bbef93c2795cbde86344 /lib
parentb4e56c6868125af8e5c773140da0775a831779d2 (diff)
Sets Content-Length to body string bytesize
Sets the Conten-Length to the bytesize of the joined body to cover UTF-8
Diffstat (limited to 'lib')
-rw-r--r--lib/zero/response.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/zero/response.rb b/lib/zero/response.rb
index 2886a0d..b8aeff0 100644
--- a/lib/zero/response.rb
+++ b/lib/zero/response.rb
@@ -42,7 +42,7 @@ module Zero
# Also creates one, if it does not exists
#
def content_length
- header['Content-Length'] = body.join.length
+ header['Content-Length'] = body.join.bytesize
end
end