[CalendarServer-changes] [5514] CalendarServer/trunk/lib-patches/vobject/vobject.vcard.patch
source_changes at macosforge.org
source_changes at macosforge.org
Thu Apr 22 17:13:43 PDT 2010
Revision: 5514
http://trac.macosforge.org/projects/calendarserver/changeset/5514
Author: cdaboo at apple.com
Date: 2010-04-22 17:13:41 -0700 (Thu, 22 Apr 2010)
Log Message:
-----------
Handle ORG property with \, in it.
Modified Paths:
--------------
CalendarServer/trunk/lib-patches/vobject/vobject.vcard.patch
Modified: CalendarServer/trunk/lib-patches/vobject/vobject.vcard.patch
===================================================================
--- CalendarServer/trunk/lib-patches/vobject/vobject.vcard.patch 2010-04-23 00:07:35 UTC (rev 5513)
+++ CalendarServer/trunk/lib-patches/vobject/vobject.vcard.patch 2010-04-23 00:13:41 UTC (rev 5514)
@@ -1,13 +1,27 @@
Index: vobject/vcard.py
===================================================================
---- vobject/vcard.py (revision 219)
+--- vobject/vcard.py (revision 218)
+++ vobject/vcard.py (working copy)
-@@ -210,7 +210,7 @@
- def splitFields(string):
+@@ -207,10 +207,10 @@
+ else:
+ return stringList
+
+-def splitFields(string):
++def splitFields(string, maybeList=True):
"""Return a list of strings or lists from a Name or Address."""
- return [toListOrString(i) for i in
+- return [toListOrString(i) for i in
- stringToTextValues(string, listSeparator=';', charList=';')]
++ return [(toListOrString(i) if maybeList else i) for i in
+ stringToTextValues(string, listSeparator=';')]
def toList(stringOrList):
if isinstance(stringOrList, basestring):
+@@ -287,7 +287,7 @@
+ """Turn obj.value into a list."""
+ if obj.isNative: return obj
+ obj.isNative = True
+- obj.value = splitFields(obj.value)
++ obj.value = splitFields(obj.value, maybeList=False)
+ return obj
+
+ @staticmethod
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/calendarserver-changes/attachments/20100422/d784feaa/attachment-0001.html>
More information about the calendarserver-changes
mailing list