1. Preston M.
  2. beaker


Preston M.  committed 8fc5130

memcached backend try use expire from the cache value

  • Participants
  • Parent commits 63501cb
  • Branches default

Comments (0)

Files changed (1)

File beaker/ext/memcached.py

View file
         return key in self
     def set_value(self, key, value, expiretime=None):
+        if expiretime is None and type(value) is tuple:
+            try:
+                expiretime = int(value[1])
+            except KeyError:
+                pass
         if expiretime:
             self.mc.set(self._format_key(key), value, time=expiretime)