chemistry-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jpo...@apache.org
Subject svn commit: r1513319 - /chemistry/cmislib/trunk/src/cmislib/atompub_binding.py
Date Tue, 13 Aug 2013 02:07:18 GMT
Author: jpotts
Date: Tue Aug 13 02:07:17 2013
New Revision: 1513319

URL: http://svn.apache.org/r1513319
Log:
Fix for CMIS-701 which is to do a reload in the getContentStream method when the content element
is missing

Modified:
    chemistry/cmislib/trunk/src/cmislib/atompub_binding.py

Modified: chemistry/cmislib/trunk/src/cmislib/atompub_binding.py
URL: http://svn.apache.org/viewvc/chemistry/cmislib/trunk/src/cmislib/atompub_binding.py?rev=1513319&r1=1513318&r2=1513319&view=diff
==============================================================================
--- chemistry/cmislib/trunk/src/cmislib/atompub_binding.py (original)
+++ chemistry/cmislib/trunk/src/cmislib/atompub_binding.py Tue Aug 13 02:07:17 2013
@@ -2475,6 +2475,11 @@ class AtomPubDocument(AtomPubCmisObject)
 
         contentElements = self.xmlDoc.getElementsByTagNameNS(ATOM_NS, 'content')
 
+        #CMIS-701
+        if len(contentElements) != 1:
+            self.reload()
+            contentElements = self.xmlDoc.getElementsByTagNameNS(ATOM_NS, 'content')
+
         assert(len(contentElements) == 1), 'Expected to find exactly one atom:content element.'
 
         # if the src element exists, follow that



Mime
View raw message