[Erp5-report] r23557 - /erp5/trunk/products/ERP5/Tool/NotificationTool.py

nobody at svn.erp5.org nobody at svn.erp5.org
Thu Sep 11 10:49:38 CEST 2008


Author: nicolas
Date: Thu Sep 11 10:49:29 2008
New Revision: 23557

URL: http://svn.erp5.org?rev=23557&view=rev
Log:
Fix a mistake inserted by variable renaming

Modified:
    erp5/trunk/products/ERP5/Tool/NotificationTool.py

Modified: erp5/trunk/products/ERP5/Tool/NotificationTool.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/Tool/NotificationTool.py?rev=23557&r1=23556&r2=23557&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/Tool/NotificationTool.py (original)
+++ erp5/trunk/products/ERP5/Tool/NotificationTool.py Thu Sep 11 10:49:29 2008
@@ -289,13 +289,15 @@
     if recipient:
       if not isinstance(recipient, (list, tuple)):
         recipient = (recipient,)
-      for person_reference in recipient:
-        if isinstance(person_reference, basestring):
-          person = catalog_tool.getResultValue(portal_type=portal_type_list,
-                                               reference=person_reference)
-          if person is None:
+      for person in recipient:
+        if isinstance(person, basestring):
+          person_value = catalog_tool.getResultValue(portal_type=portal_type_list,
+                                                     reference=person)
+          if person_value is None:
             # For backward compatibility. I recommend to use ValueError.(yusei)
-            raise IndexError, "Can't find person document which reference is '%s'" % person_reference
+            raise IndexError, "Can't find person document which reference is '%s'" % person
+          else:
+            person = person_value
         email_value = person.getDefaultEmailValue()
         if email_value is None:
           # For backward compatibility. I recommend to use ValueError.(yusei)




More information about the Erp5-report mailing list