From c716776a90da02e463040c507ea8a3f34d871cfd Mon Sep 17 00:00:00 2001 From: =?utf8?q?Thomas=20M=C3=BCller?= Date: Thu, 12 Mar 2015 21:03:26 +0100 Subject: [PATCH] cron shall not operate in case we are in maintenance mode - fixes #14843 --- cron.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/cron.php b/cron.php index 5c2cb208139..8a3240da14b 100644 --- a/cron.php +++ b/cron.php @@ -50,7 +50,11 @@ try { if (\OCP\Util::needUpgrade()) { \OCP\Util::writeLog('cron', 'Update required, skipping cron', \OCP\Util::DEBUG); - exit(); + exit; + } + if (\OC::$server->getSystemConfig()->getValue('maintenance', false)) { + \OCP\Util::writeLog('cron', 'We are in maintenance mode, skipping cron', \OCP\Util::DEBUG); + exit; } // load all apps to get all api routes properly setup -- 2.39.5