From 1f5a524c12d4d8b18d73d0bc287dbd4af01dfa5c Mon Sep 17 00:00:00 2001 From: Vincent Prouillet Date: Tue, 15 Mar 2022 11:32:31 +0100 Subject: [PATCH] Load extra themes even with theme=css Closes #1775 --- components/config/src/config/markup.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/components/config/src/config/markup.rs b/components/config/src/config/markup.rs index 5800d244e9..40c3671b31 100644 --- a/components/config/src/config/markup.rs +++ b/components/config/src/config/markup.rs @@ -108,14 +108,14 @@ impl Markdown { self.extra_syntax_set = Some(extra_syntax_set); } - if self.highlight_theme == "css" { - return Ok(()); - } - if let Some(extra_theme_set) = loaded_extra_highlight_themes { self.extra_theme_set = Arc::new(Some(extra_theme_set)); } + if self.highlight_theme == "css" { + return Ok(()); + } + // Validate that the chosen highlight_theme exists in the loaded highlight theme sets if !THEME_SET.themes.contains_key(&self.highlight_theme) { if let Some(extra) = &*self.extra_theme_set {