diff options
author | Vincent Petry <pvince81@owncloud.com> | 2014-06-26 17:10:42 +0200 |
---|---|---|
committer | Vincent Petry <pvince81@owncloud.com> | 2014-06-26 17:10:42 +0200 |
commit | 3d2fd7cd1abdad407008ac08c92d706f23b6f6ed (patch) | |
tree | bc17dca316b367a63a3480a7d693ddfa1a9362bb | |
parent | 8526556110f9fb9d2d5f9bf7742b38189f6ae482 (diff) | |
parent | 4e43e3626e3f17435d011102d97e408e856fcabd (diff) | |
download | nextcloud-server-3d2fd7cd1abdad407008ac08c92d706f23b6f6ed.tar.gz nextcloud-server-3d2fd7cd1abdad407008ac08c92d706f23b6f6ed.zip |
Merge pull request #9213 from owncloud/upgrade-donotloadappsinremote
Prevent loading apps in remote when an upgrade is due
-rw-r--r-- | remote.php | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/remote.php b/remote.php index 232e47ee402..a91742b0475 100644 --- a/remote.php +++ b/remote.php @@ -2,6 +2,15 @@ try { require_once 'lib/base.php'; + + if (\OCP\Util::needUpgrade()) { + // since the behavior of apps or remotes are unpredictable during + // an upgrade, return a 503 directly + OC_Response::setStatus(OC_Response::STATUS_SERVICE_UNAVAILABLE); + OC_Template::printErrorPage('Service unavailable'); + exit; + } + $path_info = OC_Request::getPathInfo(); if ($path_info === false || $path_info === '') { OC_Response::setStatus(OC_Response::STATUS_NOT_FOUND); |