[CalendarServer-changes] [7894] CalendarServer/branches/users/glyph/imip-and-admin-html/ twistedcaldav/mail.py

source_changes at macosforge.org source_changes at macosforge.org
Thu Aug 11 21:39:02 PDT 2011


Revision: 7894
          http://trac.macosforge.org/projects/calendarserver/changeset/7894
Author:   glyph at apple.com
Date:     2011-08-11 21:39:02 -0700 (Thu, 11 Aug 2011)
Log Message:
-----------
a little extra paranoia; since str(Component) can change the component, str() it only once and make sure the exact same text that is logged is sent.

Modified Paths:
--------------
    CalendarServer/branches/users/glyph/imip-and-admin-html/twistedcaldav/mail.py

Modified: CalendarServer/branches/users/glyph/imip-and-admin-html/twistedcaldav/mail.py
===================================================================
--- CalendarServer/branches/users/glyph/imip-and-admin-html/twistedcaldav/mail.py	2011-08-12 04:38:49 UTC (rev 7893)
+++ CalendarServer/branches/users/glyph/imip-and-admin-html/twistedcaldav/mail.py	2011-08-12 04:39:02 UTC (rev 7894)
@@ -1295,10 +1295,11 @@
                 (iconName,))
             msgHtmlRelated.attach(msgIcon)
 
+        calendarText = str(calendar)
         # the icalendar attachment
         self.log_debug("Mail gateway sending calendar body: %s"
-                       % (str(calendar)))
-        msgIcal = MIMEText(str(calendar), "calendar", "UTF-8")
+                       % (calendarText,))
+        msgIcal = MIMEText(calendarText, "calendar", "UTF-8")
         method = calendar.propertyValue("METHOD").lower()
         msgIcal.set_param("method", method)
         msgIcal.add_header("Content-ID", "<invitation.ics>")
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/calendarserver-changes/attachments/20110811/aa5e4be8/attachment.html>


More information about the calendarserver-changes mailing list