Commit cd3e4b85 authored by blackbrrr's avatar blackbrrr

fixed pickling in set method

parent 14b7c5ac
......@@ -46,6 +46,8 @@ class CacheClass(BaseCache):
"""
key = self._prepare_key(key)
# get the value from the cache
value = self._cache.get(key)
if value is None:
......@@ -68,6 +70,9 @@ class CacheClass(BaseCache):
key = self._prepare_key(key)
value = self._prepare_value(value)
# pickle the value
value = pickle.dumps(value)
# store the key/value pair
result = self._cache.set(key, value)
......
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