[Erp5-report] r18167 - /erp5/trunk/products/ERP5/Document/LeavePeriod.py

nobody at svn.erp5.org nobody at svn.erp5.org
Mon Dec 10 12:11:42 CET 2007


Author: fabien
Date: Mon Dec 10 12:11:42 2007
New Revision: 18167

URL: http://svn.erp5.org?rev=18167&view=rev
Log:
check that quantity is not None before return -quantity

Modified:
    erp5/trunk/products/ERP5/Document/LeavePeriod.py

Modified: erp5/trunk/products/ERP5/Document/LeavePeriod.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/Document/LeavePeriod.py?rev=18167&r1=18166&r2=18167&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/Document/LeavePeriod.py (original)
+++ erp5/trunk/products/ERP5/Document/LeavePeriod.py Mon Dec 10 12:11:42 2007
@@ -69,4 +69,7 @@
     quantity = PresencePeriod.getInventoriatedQuantity(
                                             self, default=default,
                                             *args, **kw)
-    return -quantity
+    if quantity is not None:
+      return -quantity
+    else:
+      return None




More information about the Erp5-report mailing list