Skip to content

The truly free, open-source, local-first, cross-platform CapCut replacement. Scriptable through a JSON-RPC API & MCP.

fix(i18n): the safe-mode notice names its keys where the locale check can find them (#507)

Jareerfba598a25ad3
diff --git a/src/crates/concat/src/lib.rs b/src/crates/concat/src/lib.rs
index 38e9fed9..84ab0a0d 100644
--- a/src/crates/concat/src/lib.rs
+++ b/src/crates/concat/src/lib.rs
@@ -319,12 +319,14 @@ fn start(project: Option<std::path::PathBuf>, smoke: bool) -> Result<(), slint::
let mut studio = Studio::new(host);
studio.set_phone(phone);
if safe {
+ // Each key in a call of its own: scripts/locales.py finds a key by
+ // the literal inside `t(...)`, and one held in a variable is lost.
let notice = if cfg!(target_os = "android") {
- "start.safeModePhone"
+ i18n::t("start.safeModePhone")
} else {
- "start.safeMode"
+ i18n::t("start.safeMode")
};
- studio.notify(&i18n::t(notice), false);
+ studio.notify(&notice, false);
}
studio.reload_packages(false);
studio.watch_packages();