Skip to content

Commit

Permalink
Let DI handle the background job
Browse files Browse the repository at this point in the history
Fixes #7548

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
  • Loading branch information
rullzer committed Dec 18, 2017
1 parent cb54330 commit 0b71369
Showing 1 changed file with 0 additions and 10 deletions.
10 changes: 0 additions & 10 deletions lib/private/Server.php
Original file line number Diff line number Diff line change
Expand Up @@ -1093,16 +1093,6 @@ public function __construct($webRoot, \OC\Config $config) {
return new CloudIdManager();
});

/* To trick DI since we don't extend the DIContainer here */
$this->registerService(CleanPreviewsBackgroundJob::class, function (Server $c) {
return new CleanPreviewsBackgroundJob(
$c->getRootFolder(),
$c->getLogger(),
$c->getJobList(),
new TimeFactory()
);
});

$this->registerAlias(\OCP\AppFramework\Utility\IControllerMethodReflector::class, \OC\AppFramework\Utility\ControllerMethodReflector::class);
$this->registerAlias('ControllerMethodReflector', \OCP\AppFramework\Utility\IControllerMethodReflector::class);

Expand Down

0 comments on commit 0b71369

Please sign in to comment.