Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
TC999 committed Jan 7, 2025
1 parent d50402b commit 2e9a276
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/confirmation.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ use crate::logger;
use crate::delete;
use crate::utils;

pub fn show_confirmation(ctx: &egui::Context, message: &str, status: &mut Option<String>) -> Option<bool> {
pub fn show_confirmation(ctx: &egui::Context, message: &str, status: &Option<String>) -> Option<bool> {
let mut result = None;

egui::Window::new("确认操作")
Expand Down
2 changes: 2 additions & 0 deletions src/ui.rs
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ pub struct AppDataCleaner {
move_module: move_module::MoveModule, // 移动模块实例
folder_descriptions: Option<FolderDescriptions>,
yaml_error_logged: bool, // 新增字段,用于标记是否已经记录过错误
status: Option<String>, // 添加 status 字段
}

impl Default for AppDataCleaner {
Expand All @@ -47,6 +48,7 @@ impl Default for AppDataCleaner {
move_module: Default::default(),
folder_descriptions: None,
yaml_error_logged: false, // 初始时假定未记录过错误
status: None, // 初始化为 None
}
}
}
Expand Down

0 comments on commit 2e9a276

Please sign in to comment.