From b5a06ecd5c0c39b218e4d6b41f4dccc5d7be7bf4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20M=C3=BCller?= Date: Mon, 7 Mar 2016 14:36:47 +0100 Subject: [PATCH] Calendar and addressbook migration commands are always available --- apps/dav/appinfo/register_command.php | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/apps/dav/appinfo/register_command.php b/apps/dav/appinfo/register_command.php index 340fbb16e9..570848f0b2 100644 --- a/apps/dav/appinfo/register_command.php +++ b/apps/dav/appinfo/register_command.php @@ -29,7 +29,6 @@ use OCA\DAV\Command\SyncSystemAddressBook; $dbConnection = \OC::$server->getDatabaseConnection(); $userManager = OC::$server->getUserManager(); $groupManager = OC::$server->getGroupManager(); -$config = \OC::$server->getConfig(); $app = new Application(); @@ -38,12 +37,5 @@ $application->add(new CreateCalendar($userManager, $groupManager, $dbConnection) $application->add(new CreateAddressBook($userManager, $app->getContainer()->query('CardDavBackend'))); $application->add(new SyncSystemAddressBook($app->getSyncService())); $application->add(new SyncBirthdayCalendar($userManager, $app->getContainer()->query('BirthdayService'))); - -// the occ tool is *for now* only available in debug mode for developers to test -if ($config->getSystemValue('debug', false)){ - $app = new \OCA\Dav\AppInfo\Application(); - $migration = $app->getContainer()->query('MigrateAddressbooks'); - $application->add(new MigrateAddressbooks($userManager, $migration)); - $migration = $app->getContainer()->query('MigrateCalendars'); - $application->add(new MigrateCalendars($userManager, $migration)); -} +$application->add(new MigrateAddressbooks($userManager, $app->getContainer()->query('MigrateAddressbooks'))); +$application->add(new MigrateCalendars($userManager, $app->getContainer()->query('MigrateCalendars')));