Compare commits

...

1 Commits

Author SHA1 Message Date
zorn 498f987fd2 \OC::server() method
Signed-off-by: zorn <zorn7@yandex.ru>
2020-01-19 12:44:12 +10:00
1 changed files with 15 additions and 1 deletions

View File

@ -123,11 +123,24 @@ class OC {
*/
public static $server = null;
/**
* @var \OC\Server
*/
private static $serverContainer = null;
/**
* @var \OC\Config
*/
private static $config = null;
/**
* @return \OC\Server
*/
public static function server()
{
return self::$serverContainer;
}
/**
* @throws \RuntimeException when the 3rdparty directory is missing or
* the app path list is empty or contains an invalid path
@ -598,7 +611,8 @@ class OC {
}
// setup the basic server
self::$server = new \OC\Server(\OC::$WEBROOT, self::$config);
self::$serverContainer = new \OC\Server(self::$WEBROOT, self::$config);
self::$server = self::$serverContainer;
\OC::$server->getEventLogger()->log('autoloader', 'Autoloader', $loaderStart, $loaderEnd);
\OC::$server->getEventLogger()->start('boot', 'Initialize');