Commit cffc1790 authored by Jean-Paul Smets's avatar Jean-Paul Smets

object_path == test now uses list()


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@718 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 01267a57
...@@ -66,7 +66,7 @@ class RAMQueue(Queue): ...@@ -66,7 +66,7 @@ class RAMQueue(Queue):
if object is not None: if object is not None:
object_path = object.getPhysicalPath() object_path = object.getPhysicalPath()
for m in self.queue: for m in self.queue:
if m.object_path == object_path: if list(m.object_path) == list(object_path):
return 1 return 1
else: else:
return 1 # Default behaviour if no object specified is to return 1 until active_process implemented return 1 # Default behaviour if no object specified is to return 1 until active_process implemented
...@@ -75,12 +75,12 @@ class RAMQueue(Queue): ...@@ -75,12 +75,12 @@ class RAMQueue(Queue):
def flush(self, activity_tool, object_path, invoke=0, method_id=None, **kw): def flush(self, activity_tool, object_path, invoke=0, method_id=None, **kw):
# Parse each message in registered # Parse each message in registered
for m in activity_tool.getRegisteredMessageList(self): for m in activity_tool.getRegisteredMessageList(self):
if object_path == m.object_path and (method_id is None or method_id == m.method_id): if list(m.object_path) == list(object_path) and (method_id is None or method_id == m.method_id):
if invoke: activity_tool.invoke(m) if invoke: activity_tool.invoke(m)
activity_tool.unregisterMessage(self, m) activity_tool.unregisterMessage(self, m)
# Parse each message in queue # Parse each message in queue
for m in self.queue: for m in self.queue:
if object_path == m.object_path and (method_id is None or method_id == m.method_id): if list(m.object_path) == list(object_path) and (method_id is None or method_id == m.method_id):
if invoke: activity_tool.invoke(m) if invoke: activity_tool.invoke(m)
self.deleteMessage(activity_tool, m) self.deleteMessage(activity_tool, m)
......
...@@ -186,7 +186,7 @@ class SQLDict(RAMDict): ...@@ -186,7 +186,7 @@ class SQLDict(RAMDict):
method_dict = {} method_dict = {}
# Parse each message in registered # Parse each message in registered
for m in activity_tool.getRegisteredMessageList(self): for m in activity_tool.getRegisteredMessageList(self):
if object_path == m.object_path and (method_id is None or method_id == m.method_id): if list(m.object_path) == list(object_path) and (method_id is None or method_id == m.method_id):
activity_tool.unregisterMessage(self, m) activity_tool.unregisterMessage(self, m)
if not method_dict.has_key(method_id): if not method_dict.has_key(method_id):
if invoke: if invoke:
......
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