tdiary/tdiary-core — Issue #109: 304 Not Modifiedが返らない
Author: elpeo
Created: 2011-10-30 11:57:04+00:00
State: open

Index: tdiary/dispatcher/index_main.rb
===================================================================
--- tdiary/dispatcher/index_main.rb (リビジョン 3709)
+++ tdiary/dispatcher/index_main.rb (作業コピー)
@@ -43,7 +43,7 @@
body = tdiary.eval_rhtml
head['ETag'] = %Q["#{Digest::MD5.hexdigest( body )}"]
if ENV['HTTP_IF_NONE_MATCH'] == head['ETag'] and request.get? then
- status = CGI::HTTP_STATUS['NOT_MODIFIED']
+ head['status'] = CGI::HTTP_STATUS['NOT_MODIFIED']
else
head['charset'] = conf.encoding
head['Content-Length'] = body.bytesize.to_s