[Neo-report] r2425 vincent - /trunk/neo/client/handlers/master.py
nobody at svn.erp5.org
nobody at svn.erp5.org
Sat Nov 6 00:23:00 CET 2010
Author: vincent
Date: Sat Nov 6 00:23:00 2010
New Revision: 2425
Log:
Avoid creating a variable when not needed.
Modified:
trunk/neo/client/handlers/master.py
Modified: trunk/neo/client/handlers/master.py
==============================================================================
--- trunk/neo/client/handlers/master.py [iso-8859-1] (original)
+++ trunk/neo/client/handlers/master.py [iso-8859-1] Sat Nov 6 00:23:00 2010
@@ -124,13 +124,12 @@ class PrimaryNotificationsHandler(BaseHa
try:
# ZODB required a dict with oid as key, so create it
mq_cache = app.mq_cache
- oids = dict.fromkeys(oid_list, tid)
for oid in oid_list:
if oid in mq_cache:
del mq_cache[oid]
db = app.getDB()
if db is not None:
- db.invalidate(tid, oids)
+ db.invalidate(tid, dict.fromkeys(oid_list, tid))
finally:
app._cache_lock_release()
More information about the Neo-report
mailing list