Use \OCP\IContainer::injectFn to boot the admin_audit app

Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
This commit is contained in:
Christoph Wurst 2020-06-29 16:09:58 +02:00
parent 58b8b00798
commit 9993a3b839
No known key found for this signature in database
GPG Key ID: CC42AC2A7F0E56D8
1 changed files with 4 additions and 4 deletions

View File

@ -33,6 +33,7 @@ declare(strict_types=1);
namespace OCA\AdminAudit\AppInfo;
use Closure;
use OC\Files\Filesystem;
use OC\Files\Node\File;
use OC\Group\Manager;
@ -78,10 +79,9 @@ class Application extends App implements IBootstrap {
}
public function boot(IBootContext $context): void {
$logger = $this->getLogger(
$context->getAppContainer()->query(IConfig::class),
$context->getAppContainer()->query(ILogger::class),
$context->getAppContainer()->query(ILogFactory::class)
/** @var ILogger $logger */
$logger = $context->injectFn(
Closure::fromCallable([$this, 'getLogger'])
);
/*