diff --git a/ftd/src/executor/code.rs b/ftd/src/executor/code.rs index 91fd3048f8..6adc290e87 100644 --- a/ftd/src/executor/code.rs +++ b/ftd/src/executor/code.rs @@ -60,7 +60,8 @@ pub fn code(code: &str, ext: &str, theme: &str, doc_id: &str) -> ftd::executor:: .find_syntax_by_extension(ext) .unwrap_or_else(|| SS.find_syntax_plain_text()); - let theme = if let Some(theme) = TS.themes.get(theme).or(ts1().themes.get(theme)) { + let ts1 = ts1(); + let theme = if let Some(theme) = TS.themes.get(theme).or(ts1.themes.get(theme)) { theme } else { return Err(ftd::executor::Error::ParseError {