[CalendarServer-changes] [13721] CalendarServer/trunk/twistedcaldav/directory/principal.py

source_changes at macosforge.org source_changes at macosforge.org
Thu Jul 3 15:20:57 PDT 2014


Revision: 13721
          http://trac.calendarserver.org//changeset/13721
Author:   sagen at apple.com
Date:     2014-07-03 15:20:57 -0700 (Thu, 03 Jul 2014)
Log Message:
-----------
Only add /principals/wiki resource if wiki is actually enabled

Modified Paths:
--------------
    CalendarServer/trunk/twistedcaldav/directory/principal.py

Modified: CalendarServer/trunk/twistedcaldav/directory/principal.py
===================================================================
--- CalendarServer/trunk/twistedcaldav/directory/principal.py	2014-07-03 21:30:11 UTC (rev 13720)
+++ CalendarServer/trunk/twistedcaldav/directory/principal.py	2014-07-03 22:20:57 UTC (rev 13721)
@@ -290,15 +290,17 @@
         #
         # Create children
         #
-
-        self.supportedChildTypes = (
+        self.supportedChildTypes = [
             self.directory.recordType.user,
             self.directory.recordType.group,
             self.directory.recordType.location,
             self.directory.recordType.resource,
             self.directory.recordType.address,
-            self.directory.recordType.macOSXServerWiki,
-        )
+        ]
+        if config.Authentication.Wiki.Enabled:
+            self.supportedChildTypes.append(
+                self.directory.recordType.macOSXServerWiki
+            )
 
         for name, recordType in [
             (self.directory.recordTypeToOldName(r), r)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/calendarserver-changes/attachments/20140703/46892a63/attachment-0001.html>


More information about the calendarserver-changes mailing list