Move \OC\AppFramework to PSR-4

* Also moved the autoloader setup a bit up since we need it in initpaths
This commit is contained in:
Roeland Jago Douma 2016-04-22 15:28:09 +02:00
parent 606b756a94
commit 1d33a5ef13
No known key found for this signature in database
GPG key ID: 1E152838F164D13B
23 changed files with 5 additions and 5 deletions

View file

@ -488,6 +488,9 @@ class OC {
self::$CLI = (php_sapi_name() == 'cli'); self::$CLI = (php_sapi_name() == 'cli');
// Add default composer PSR-4 autoloader
require_once OC::$SERVERROOT . '/lib/composer/autoload.php';
try { try {
self::initPaths(); self::initPaths();
// setup 3rdparty autoloader // setup 3rdparty autoloader
@ -507,9 +510,6 @@ class OC {
exit(); exit();
} }
// Add default composer PSR-4 autoloader
require_once OC::$SERVERROOT . '/lib/composer/autoload.php';
// setup the basic server // setup the basic server
self::$server = new \OC\Server(\OC::$WEBROOT, self::$config); self::$server = new \OC\Server(\OC::$WEBROOT, self::$config);
\OC::$server->getEventLogger()->log('autoloader', 'Autoloader', $loaderStart, $loaderEnd); \OC::$server->getEventLogger()->log('autoloader', 'Autoloader', $loaderStart, $loaderEnd);

View file

@ -21,7 +21,7 @@
* *
*/ */
namespace OC\AppFramework\routing; namespace OC\AppFramework\Routing;
use \OC\AppFramework\App; use \OC\AppFramework\App;
use \OC\AppFramework\DependencyInjection\DIContainer; use \OC\AppFramework\DependencyInjection\DIContainer;

View file

@ -24,7 +24,7 @@
* *
*/ */
namespace OC\AppFramework\routing; namespace OC\AppFramework\Routing;
use OC\AppFramework\DependencyInjection\DIContainer; use OC\AppFramework\DependencyInjection\DIContainer;
use OCP\Route\IRouter; use OCP\Route\IRouter;