diff options
author | Joas Schilling <nickvergessen@owncloud.com> | 2015-04-08 12:51:20 +0200 |
---|---|---|
committer | Joas Schilling <nickvergessen@owncloud.com> | 2015-04-08 12:51:20 +0200 |
commit | f7dd16f1ac07807824b3ccc58c27e74b462088ae (patch) | |
tree | 743945933d9a418f866d3aad6e5aeb462810dd22 /ocs | |
parent | 59322a50371227c955bef392ccae4d091e248299 (diff) | |
download | nextcloud-server-f7dd16f1ac07807824b3ccc58c27e74b462088ae.tar.gz nextcloud-server-f7dd16f1ac07807824b3ccc58c27e74b462088ae.zip |
Disable OCS api when in maintenance mode
Diffstat (limited to 'ocs')
-rw-r--r-- | ocs/v1.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ocs/v1.php b/ocs/v1.php index 5bba65d9a1a..398a128c64b 100644 --- a/ocs/v1.php +++ b/ocs/v1.php @@ -27,7 +27,7 @@ require_once '../lib/base.php'; -if (\OCP\Util::needUpgrade()) { +if (\OCP\Util::needUpgrade() || \OC::$server->getSystemConfig()->getValue('maintenance', false)) { // since the behavior of apps or remotes are unpredictable during // an upgrade, return a 503 directly OC_Response::setStatus(OC_Response::STATUS_SERVICE_UNAVAILABLE); |