Permalink
Browse files

make sure the Cache-Control header can never be nil

  • Loading branch information...
1 parent d27a404 commit fe492baa38014378981bef71e37921d72e121083 @mmb mmb committed with rkh Jun 27, 2011
Showing with 2 additions and 1 deletion.
  1. +2 −1 lib/rack/etag.rb
View
3 lib/rack/etag.rb
@@ -28,7 +28,8 @@ def call(env)
end
unless headers['Cache-Control']
- headers['Cache-Control'] = digest ? @cache_control : @no_cache_control
+ headers['Cache-Control'] =
+ (digest ? @cache_control : @no_cache_control) || []
end
[status, headers, body]

0 comments on commit fe492ba

Please sign in to comment.