Merge pull request #9419 from nextcloud/feature/noid/isCLI_parameter

Expose isCLI to DI
This commit is contained in:
Roeland Jago Douma 2018-05-08 14:16:15 +02:00 committed by GitHub
commit c40f7cd283
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 0 deletions

View File

@ -164,6 +164,9 @@ class Server extends ServerContainer implements IServerContainer {
parent::__construct();
$this->webRoot = $webRoot;
// To find out if we are running from CLI or not
$this->registerParameter('isCLI', \OC::$CLI);
$this->registerService(\OCP\IServerContainer::class, function (IServerContainer $c) {
return $c;
});