summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVictor Dubiniuk <victor.dubiniuk@gmail.com>2016-09-06 23:19:07 +0300
committerVictor Dubiniuk <victor.dubiniuk@gmail.com>2016-09-06 23:32:14 +0300
commita2d01aab8a1990fd7813d835865a478f5ecaf6eb (patch)
treea827b9632846a8f621928c5a9a842707e6eb88f1
parent7cc8f4d7e922ddf4b4c7a669b8295aa003c1736d (diff)
downloadnextcloud-server-a2d01aab8a1990fd7813d835865a478f5ecaf6eb.tar.gz
nextcloud-server-a2d01aab8a1990fd7813d835865a478f5ecaf6eb.zip
Pass web requests to occ controller if upgrade is needed
-rw-r--r--lib/base.php6
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/base.php b/lib/base.php
index 1f3079b039e..9d0b1219f54 100644
--- a/lib/base.php
+++ b/lib/base.php
@@ -890,6 +890,12 @@ class OC {
OC_Util::setupFS();
OC::$server->getRouter()->match(\OC::$server->getRequest()->getRawPathInfo());
return;
+ } catch (\OC\NeedsUpdateException $e) {
+ if ($isOccControllerRequested && $needUpgrade){
+ OC::$server->getRouter()->match(\OC::$server->getRequest()->getRawPathInfo());
+ return;
+ }
+ throw $e;
} catch (Symfony\Component\Routing\Exception\ResourceNotFoundException $e) {
//header('HTTP/1.0 404 Not Found');
} catch (Symfony\Component\Routing\Exception\MethodNotAllowedException $e) {