Merge pull request #23542 from owncloud/catch-empty-app-path-oh-we-really-should-use-exceptions-in-the-future

getAppPath can return false
remotes/origin/add-expiration-date-row
Thomas Müller 10 years ago
commit 789df4d630
  1. 9
      lib/private/route/router.php

@ -95,9 +95,12 @@ class Router implements IRouter {
if (!isset($this->routingFiles)) {
$this->routingFiles = [];
foreach (\OC_APP::getEnabledApps() as $app) {
$file = \OC_App::getAppPath($app) . '/appinfo/routes.php';
if (file_exists($file)) {
$this->routingFiles[$app] = $file;
$appPath = \OC_App::getAppPath($app);
if($appPath !== false) {
$file = $appPath . '/appinfo/routes.php';
if (file_exists($file)) {
$this->routingFiles[$app] = $file;
}
}
}
}

Loading…
Cancel
Save