Skip to content

Commit e3c940a

Browse files
ArtificialOwlAndyScherzinger
authored andcommitted
fix(setup): ignore missing theming app
Signed-off-by: Maxence Lange <[email protected]>
1 parent c02cdcc commit e3c940a

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

lib/private/TemplateLayout.php

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -180,8 +180,12 @@ public function __construct($renderAs, $appId = '') {
180180
}
181181

182182
// Set body data-theme
183-
$themesService = \OCP\Server::get(\OCA\Theming\Service\ThemesService::class);
184-
$this->assign('enabledThemes', $themesService->getEnabledThemes());
183+
try {
184+
$themesService = \OCP\Server::get(\OCA\Theming\Service\ThemesService::class);
185+
} catch (\OCP\AppFramework\QueryException) {
186+
$themesService = null;
187+
}
188+
$this->assign('enabledThemes', $themesService?->getEnabledThemes() ?? []);
185189

186190
// Send the language, locale, and direction to our layouts
187191
$lang = \OC::$server->get(IFactory::class)->findLanguage();

0 commit comments

Comments
 (0)