[Erp5-report] r25389 - /erp5/trunk/products/ERP5SyncML/SynchronizationTool.py

nobody at svn.erp5.org nobody at svn.erp5.org
Fri Jan 30 17:14:19 CET 2009


Author: nicolas
Date: Fri Jan 30 17:14:18 2009
New Revision: 25389

URL: http://svn.erp5.org?rev=25389&view=rev
Log:
lxml supply xml delaration, no need t add it

Modified:
    erp5/trunk/products/ERP5SyncML/SynchronizationTool.py

Modified: erp5/trunk/products/ERP5SyncML/SynchronizationTool.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5SyncML/SynchronizationTool.py?rev=25389&r1=25388&r2=25389&view=diff
==============================================================================
--- erp5/trunk/products/ERP5SyncML/SynchronizationTool.py [utf8] (original)
+++ erp5/trunk/products/ERP5SyncML/SynchronizationTool.py [utf8] Fri Jan 30 17:14:18 2009
@@ -901,13 +901,7 @@
         auth_handler, TimeoutHTTPHandler)
     urllib2.install_opener(opener)
     to_encode = {}
-    head = '<?xml version="1.0" encoding="UTF-8"?>'
-
-    if content_type == self.CONTENT_TYPE['SYNCML_WBXML']:
-      #because xml2wbxml add the head to the xml
-      to_encode['text'] = xml
-    else:
-      to_encode['text'] = head + xml
+    to_encode['text'] = xml
     to_encode['sync_id'] = sync_id
     headers = {'User-Agent':'ERP5SyncML', 'Content-Type':content_type}
 




More information about the Erp5-report mailing list