only quit if changes are saved

This commit is contained in:
alice pellerin
2026-03-18 19:25:48 -05:00
parent a699c0a371
commit 2ee61fef71
3 changed files with 16 additions and 4 deletions
+2 -2
View File
@@ -168,11 +168,11 @@ impl App {
}
}
const fn has_unsaved_changes(&self) -> bool {
pub const fn has_unsaved_changes(&self) -> bool {
!self.all_changes_saved()
}
const fn all_changes_saved(&self) -> bool {
pub const fn all_changes_saved(&self) -> bool {
if let Some(last_saved_at) = self.last_saved_at {
if let Some(time_traveling) = self.time_traveling {
last_saved_at == time_traveling