logger = $logger; $this->l10n = $l10n; $this->defaultBoardService = $defaultBoardService; $this->permissionService = $permissionService; $this->userId = $userId; } public function beforeController($controller, $methodName) { try { if ($this->userId !== null && $this->defaultBoardService->checkFirstRun($this->userId) && $this->permissionService->canCreate()) { $this->defaultBoardService->createDefaultBoard($this->l10n->t('Personal'), $this->userId, '0087C5'); } } catch (\Throwable $e) { $this->logger->logException($e); } } }