From c309e8afc91426ec8c4150e78cfe40c73af821d0 Mon Sep 17 00:00:00 2001 From: echel0n Date: Sat, 29 Mar 2014 01:00:42 -0700 Subject: [PATCH] Fixed bug in cache controller --- lib/cachecontrol/controller.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/cachecontrol/controller.py b/lib/cachecontrol/controller.py index 5d283697..680479a3 100644 --- a/lib/cachecontrol/controller.py +++ b/lib/cachecontrol/controller.py @@ -191,7 +191,7 @@ class CacheController(object): return if self.sess.cache_auto and ('cache-control' not in resp.headers or 'Cache-Control' not in resp.headers): - cache_max_age = int(self.sess.cache_max_age) or 900 + cache_max_age = int(self.sess.cache_max_age or 900) headers = {'Cache-Control': 'public,max-age=%d' % int(cache_max_age)} resp.headers.update(headers)