diff options
author | Thomas Mueller <thomas.mueller@tmit.eu> | 2013-01-18 23:22:34 +0100 |
---|---|---|
committer | Thomas Mueller <thomas.mueller@tmit.eu> | 2013-01-18 23:22:34 +0100 |
commit | afb5de955e00490be5762247e817b20722091f37 (patch) | |
tree | 035b826eacc5a21244c383075138731eaafeaebc /lib/router.php | |
parent | 130c9cad030ca777e23ef70b76822553ea1c6411 (diff) | |
parent | 31cc9aa80d4284e13dc95d2ef1428bed78c22d65 (diff) | |
download | nextcloud-server-afb5de955e00490be5762247e817b20722091f37.tar.gz nextcloud-server-afb5de955e00490be5762247e817b20722091f37.zip |
Merge branch 'master' into fixing-998-master
Conflicts:
apps/files/ajax/upload.php
apps/files/js/files.js
Diffstat (limited to 'lib/router.php')
-rw-r--r-- | lib/router.php | 22 |
1 files changed, 5 insertions, 17 deletions
diff --git a/lib/router.php b/lib/router.php index 27e14c38abf..746b68c2c0c 100644 --- a/lib/router.php +++ b/lib/router.php @@ -49,6 +49,7 @@ class OC_Router { $files = $this->getRoutingFiles(); $files[] = 'settings/routes.php'; $files[] = 'core/routes.php'; + $files[] = 'ocs/routes.php'; $this->cache_key = OC_Cache::generateCacheKeyFromFiles($files); } return $this->cache_key; @@ -58,23 +59,6 @@ class OC_Router { * loads the api routes */ public function loadRoutes() { - - // TODO cache - $this->root = $this->getCollection('root'); - foreach(OC_APP::getEnabledApps() as $app){ - $file = OC_App::getAppPath($app).'/appinfo/routes.php'; - if(file_exists($file)){ - $this->useCollection($app); - require_once($file); - $collection = $this->getCollection($app); - $this->root->addCollection($collection, '/apps/'.$app); - } - } - // include ocs routes - require_once(OC::$SERVERROOT.'/ocs/routes.php'); - $collection = $this->getCollection('ocs'); - $this->root->addCollection($collection, '/ocs'); - foreach($this->getRoutingFiles() as $app => $file) { $this->useCollection($app); require_once $file; @@ -85,6 +69,10 @@ class OC_Router { require_once 'settings/routes.php'; require_once 'core/routes.php'; + // include ocs routes + require_once 'ocs/routes.php'; + $collection = $this->getCollection('ocs'); + $this->root->addCollection($collection, '/ocs'); } protected function getCollection($name) { |