refactor: simplify auto proxy disabling logic in clean_async function

This commit is contained in:
Tunglies
2025-10-06 18:26:01 +08:00
parent b0decf824e
commit abb0df59df

View File

@@ -130,12 +130,9 @@ async fn clean_async() -> bool {
} }
// 关闭自动代理配置 // 关闭自动代理配置
match Autoproxy::get_auto_proxy() { if let Ok(mut autoproxy) = Autoproxy::get_auto_proxy() {
Ok(mut autoproxy) => { autoproxy.enable = false;
autoproxy.enable = false; let _ = autoproxy.set_auto_proxy();
let _ = autoproxy.set_auto_proxy();
}
Err(_) => {}
} }
return true; return true;