diff options
author | Joas Schilling <coding@schilljs.com> | 2017-10-19 11:57:52 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-10-19 11:57:52 +0200 |
commit | bb1af9b2842f070dbd3462125f46e3d102fe812b (patch) | |
tree | 5afd2346f3839e8283912dcf1f7baf93d151e7c5 /apps/dav/appinfo/v1/caldav.php | |
parent | 7de6f7cd077bc6aab052b00f3c785f9b79efc076 (diff) | |
parent | b958725f78ade3f116001ee6dd66432bffa41748 (diff) | |
download | nextcloud-server-bb1af9b2842f070dbd3462125f46e3d102fe812b.tar.gz nextcloud-server-bb1af9b2842f070dbd3462125f46e3d102fe812b.zip |
Merge pull request #6811 from nextcloud/feature/noid/disable_caldav_invitations
Opt out of IMip CalDAV Plugin
Diffstat (limited to 'apps/dav/appinfo/v1/caldav.php')
-rw-r--r-- | apps/dav/appinfo/v1/caldav.php | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/apps/dav/appinfo/v1/caldav.php b/apps/dav/appinfo/v1/caldav.php index b005ec2fcb8..a103f82a420 100644 --- a/apps/dav/appinfo/v1/caldav.php +++ b/apps/dav/appinfo/v1/caldav.php @@ -52,6 +52,7 @@ $dispatcher = \OC::$server->getEventDispatcher(); $calDavBackend = new CalDavBackend($db, $principalBackend, $userManager, \OC::$server->getGroupManager(), $random, $dispatcher, true); $debugging = \OC::$server->getConfig()->getSystemValue('debug', false); +$sendInvitations = \OC::$server->getConfig()->getAppValue('dav', 'sendInvitations', 'yes') === 'yes'; // Root nodes $principalCollection = new \Sabre\CalDAV\Principal\Collection($principalBackend); @@ -84,7 +85,11 @@ if ($debugging) { $server->addPlugin(new \Sabre\DAV\Sync\Plugin()); $server->addPlugin(new \Sabre\CalDAV\ICSExportPlugin()); $server->addPlugin(new \OCA\DAV\CalDAV\Schedule\Plugin()); -$server->addPlugin(new \OCA\DAV\CalDAV\Schedule\IMipPlugin( \OC::$server->getMailer(), \OC::$server->getLogger(), new \OC\AppFramework\Utility\TimeFactory())); + +if ($sendInvitations) { + $server->addPlugin(new \OCA\DAV\CalDAV\Schedule\IMipPlugin( \OC::$server->getMailer(), \OC::$server->getLogger(), new \OC\AppFramework\Utility\TimeFactory())); +} + $server->addPlugin(new ExceptionLoggerPlugin('caldav', \OC::$server->getLogger())); // And off we go! |