Skip to content

Commit

Permalink
Merge branch '2' into 3
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions[bot] committed Oct 27, 2024
2 parents 8e22e6f + 490bfe5 commit 476b0f6
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/ErrorPage.php
Original file line number Diff line number Diff line change
Expand Up @@ -330,6 +330,7 @@ public function writeStaticPage()
// Run the page (reset the theme, it might've been disabled by LeftAndMain::init())
$originalThemes = SSViewer::get_themes();
try {
$this->extend('onBeforeStaticWrite');
// Restore front-end themes from config
$themes = SSViewer::config()->get('themes') ?: $originalThemes;
SSViewer::set_themes($themes);
Expand All @@ -344,6 +345,7 @@ public function writeStaticPage()
} finally {
// Restore themes
SSViewer::set_themes($originalThemes);
$this->extend('onAfterStaticWrite');
}

// Make sure we have content to save
Expand Down

0 comments on commit 476b0f6

Please sign in to comment.