Commit e8ff7064 authored by Grégory Wisniewski's avatar Grégory Wisniewski

Factorize cache entry access.


git-svn-id: https://svn.erp5.org/repos/neo/branches/prototype3@931 71dcc9de-d417-0410-9af5-da40c76e7ee4
parent 58ecdcc3
...@@ -605,7 +605,8 @@ class Application(object): ...@@ -605,7 +605,8 @@ class Application(object):
try: try:
if oid in self.mq_cache: if oid in self.mq_cache:
logging.debug('load oid %s is cached', dump(oid)) logging.debug('load oid %s is cached', dump(oid))
return self.mq_cache[oid][1], self.mq_cache[oid][0] serial, data = self.mq_cache[oid]
return data, serial
finally: finally:
self._cache_lock_release() self._cache_lock_release()
# Otherwise get it from storage node # Otherwise get it from storage node
......
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