[Erp5-report] r32281 aurel - /erp5/trunk/products/ERP5/Document/Document.py
nobody at svn.erp5.org
nobody at svn.erp5.org
Fri Feb 5 10:29:08 CET 2010
Author: aurel
Date: Fri Feb 5 10:29:06 2010
New Revision: 32281
URL: http://svn.erp5.org?rev=32281&view=rev
Log:
Avoid failure when calling hasData as Document object does not have
'data' property defined by default
Modified:
erp5/trunk/products/ERP5/Document/Document.py
Modified: erp5/trunk/products/ERP5/Document/Document.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/Document/Document.py?rev=32281&r1=32280&r2=32281&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/Document/Document.py [utf8] (original)
+++ erp5/trunk/products/ERP5/Document/Document.py [utf8] Fri Feb 5 10:29:06 2010
@@ -1276,7 +1276,7 @@
using the base_data property. Refer to Document.py propertysheet.
Use accessors (getBaseData, setBaseData, hasBaseData, etc.)
"""
- if not self.hasData():
+ if getattr(self, 'hasData', None) is not None and not self.hasData():
# Empty document cannot be converted
return #'Document is empty'
try:
More information about the Erp5-report
mailing list