30 lines
1.1 KiB
Diff
30 lines
1.1 KiB
Diff
From 62e6eb13c0df3c0925420fa393eeafb3e211dc4e Mon Sep 17 00:00:00 2001
|
|
From: Astro <astro@spaceboyz.net>
|
|
Date: Mon, 4 Dec 2023 02:43:16 +0100
|
|
Subject: [PATCH 2/2] plume-front: fixup
|
|
|
|
---
|
|
plume-front/src/editor.rs | 3 ++-
|
|
1 file changed, 2 insertions(+), 1 deletion(-)
|
|
|
|
diff --git a/plume-front/src/editor.rs b/plume-front/src/editor.rs
|
|
index 94bbbb59..1bef5004 100644
|
|
--- a/plume-front/src/editor.rs
|
|
+++ b/plume-front/src/editor.rs
|
|
@@ -168,10 +168,11 @@ fn load_autosave() {
|
|
.get(&get_autosave_id())
|
|
{
|
|
let autosave_info: AutosaveInformation = serde_json::from_str(&autosave_str).ok().unwrap();
|
|
+ let last_saved = Date::new(&JsValue::from_f64(autosave_info.last_saved)).to_date_string().as_string().unwrap();
|
|
let message = i18n!(
|
|
CATALOG,
|
|
"Do you want to load the local autosave last edited at {}?";
|
|
- Date::new(&JsValue::from_f64(autosave_info.last_saved)).to_date_string().as_string().unwrap()
|
|
+ last_saved
|
|
);
|
|
if let Ok(true) = window().unwrap().confirm_with_message(&message) {
|
|
set_value("editor-content", &autosave_info.contents);
|
|
--
|
|
2.42.0
|
|
|