Commit 1fa3544c authored by Nicolas Delaby's avatar Nicolas Delaby

coding style

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@29640 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent d07a958f
...@@ -69,7 +69,7 @@ class CacheFactory: ...@@ -69,7 +69,7 @@ class CacheFactory:
## separete local and shared cache plugins ## separete local and shared cache plugins
self.quick_cache = self.cache_plugins[0] self.quick_cache = self.cache_plugins[0]
try: try:
self.shared_caches =self.cache_plugins[1:] self.shared_caches = self.cache_plugins[1:]
except IndexError: except IndexError:
self.shared_caches = [] self.shared_caches = []
...@@ -79,7 +79,7 @@ class CacheFactory: ...@@ -79,7 +79,7 @@ class CacheFactory:
self._last_cache_expire_check_at = time() self._last_cache_expire_check_at = time()
for cp in self.cache_plugins: for cp in self.cache_plugins:
l.append(cp.cache_expire_check_interval) l.append(cp.cache_expire_check_interval)
l = filter(lambda x: x!=None and x!=0, l) l = filter(lambda x: x is not None and x != 0, l)
self.cache_expire_check_interval = min(l) self.cache_expire_check_interval = min(l)
def __call__(self, callable_object, cache_id, scope, cache_duration=None, *args, **kwd): def __call__(self, callable_object, cache_id, scope, cache_duration=None, *args, **kwd):
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment