提交 a1ff5585 编写于 作者: A Aaron Patterson

fewer calls to `env`

We don't want to directly access the env hash
上级 f5f4d135
......@@ -8,13 +8,13 @@ module Request
HTTP_IF_NONE_MATCH = 'HTTP_IF_NONE_MATCH'.freeze
def if_modified_since
if since = env[HTTP_IF_MODIFIED_SINCE]
if since = get_header(HTTP_IF_MODIFIED_SINCE)
Time.rfc2822(since) rescue nil
end
end
def if_none_match
env[HTTP_IF_NONE_MATCH]
get_header HTTP_IF_NONE_MATCH
end
def if_none_match_etags
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册