From a2e6c299cd15b8335441e3b5ba07fe95256f3a2d Mon Sep 17 00:00:00 2001 From: Stormwind Date: Fri, 23 Nov 2012 18:06:53 +0100 Subject: Sets Content-Length to body string bytesize Sets the Conten-Length to the bytesize of the joined body to cover UTF-8 --- lib/zero/response.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib') 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 -- cgit v1.2.3-70-g09d2