getContainer(); $container->registerMiddleWare(JoinMiddleware::class); $config = $container->query(IConfig::class); if ($config->getAppValue('bbb', 'app.navigation') === 'true') { $this->registerAsNavigationEntry(); } else { $this->registerAsPersonalSetting(); } } private function registerAsPersonalSetting() { $settingsManager = $this->getContainer()->getServer()->getSettingsManager(); $settingsManager->registerSection('personal', \OCA\BigBlueButton\Settings\Section::class); $settingsManager->registerSetting('personal', \OCA\BigBlueButton\Settings\Personal::class); } private function registerAsNavigationEntry() { $server = $this->getContainer()->getServer(); $server->getNavigationManager()->add(function () use ($server) { return [ 'id' => 'bbb', 'order' => 80, 'href' => $server->getURLGenerator()->linkToRoute('bbb.page.index'), 'icon' => $server->getURLGenerator()->imagePath('bbb', 'app.svg'), 'name' => 'BigBlueButton', ]; }); } }