summaryrefslogtreecommitdiff
path: root/cheetah/CacheStore.py
diff options
context:
space:
mode:
Diffstat (limited to 'cheetah/CacheStore.py')
-rw-r--r--cheetah/CacheStore.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/cheetah/CacheStore.py b/cheetah/CacheStore.py
index 9c41656..8f57f33 100644
--- a/cheetah/CacheStore.py
+++ b/cheetah/CacheStore.py
@@ -46,12 +46,12 @@ class MemoryCacheStore(AbstractCacheStore):
self._data[key] = (val, time)
def add(self, key, val, time=0):
- if self._data.has_key(key):
+ if key in self._data:
raise Error('a value for key %r is already in the cache'%key)
self._data[key] = (val, time)
def replace(self, key, val, time=0):
- if self._data.has_key(key):
+ if key in self._data:
raise Error('a value for key %r is already in the cache'%key)
self._data[key] = (val, time)