[CalendarServer-changes] [2934] CalendarServer/trunk/twistedcaldav/ical.py

source_changes at macosforge.org source_changes at macosforge.org
Wed Sep 3 15:14:30 PDT 2008


Revision: 2934
          http://trac.macosforge.org/projects/calendarserver/changeset/2934
Author:   wsanchez at apple.com
Date:     2008-09-03 15:14:29 -0700 (Wed, 03 Sep 2008)
Log Message:
-----------
Make sure vobject does what we expect

Modified Paths:
--------------
    CalendarServer/trunk/twistedcaldav/ical.py

Modified: CalendarServer/trunk/twistedcaldav/ical.py
===================================================================
--- CalendarServer/trunk/twistedcaldav/ical.py	2008-09-03 14:10:38 UTC (rev 2933)
+++ CalendarServer/trunk/twistedcaldav/ical.py	2008-09-03 22:14:29 UTC (rev 2934)
@@ -129,8 +129,7 @@
         ValueError if the parameter has more than one value.
         """
         values = self._vobject.params.get(name, [None,])
-        if type(values) is not list:
-            values = [values]
+        assert type(values) is list, "vobject returned non-list value for parameter %r in property %r" % (name, self)
         if len(values) != 1:
             raise ValueError("Not exactly one %s value in property %r" % (name, self))
         return values[0]
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.macosforge.org/pipermail/calendarserver-changes/attachments/20080903/f514610a/attachment.html 


More information about the calendarserver-changes mailing list