Enable the view module in maintenance mode

- This allows to load the default theme CSS
- Theme scripts have been updated to reflect the possibility they will be included in maintenance mode
This commit is contained in:
Hypolite Petovan 2022-07-12 19:48:36 -04:00
parent ac56dcd50f
commit 1d94e2866a
10 changed files with 177 additions and 141 deletions

View file

@ -705,7 +705,8 @@ class App
// Initialize module that can set the current theme in the init() method, either directly or via App->setProfileOwner
$page['page_title'] = $moduleName;
if (!$this->mode->isInstall() && !$this->mode->has(App\Mode::MAINTENANCEDISABLED)) {
// The "view" module is required to show the theme CSS
if (!$this->mode->isInstall() && !$this->mode->has(App\Mode::MAINTENANCEDISABLED) && $moduleName !== 'view') {
$module = $router->getModule(Maintenance::class);
} else {
// determine the module class and save it to the module instance