chore: merge dev into backend cleanup

This commit is contained in:
Tunglies
2026-11-02 18:55:49 +08:00
31 changed files with 1287 additions and 525 deletions
+2 -2
View File
@@ -106,14 +106,14 @@ impl AutoBackupManager {
pub async fn init(&self) -> Result<()> {
let settings = Self::load_settings().await;
let _ = self.settings_tx.send(settings);
let _ = self.settings_tx.send_replace(settings);
self.maybe_start_runner(settings);
Ok(())
}
pub async fn refresh_settings(&self) -> Result<()> {
let settings = Self::load_settings().await;
let _ = self.settings_tx.send(settings);
let _ = self.settings_tx.send_replace(settings);
self.maybe_start_runner(settings);
Ok(())
}
+1 -1
View File
@@ -27,7 +27,7 @@ pub async fn patch_verge(patch: &IVerge, not_save_file: bool) -> Result<()> {
/// Apply a patch without post-update reconciliation.
pub(super) async fn apply_verge_patch(patch: &IVerge, not_save_file: bool) -> Result<()> {
let config_write = Config::try_lock_config_write()?;
let config_write = Config::lock_config_write().await;
apply_verge_patch_locked(&config_write, patch, not_save_file).await
}
-1
View File
@@ -321,7 +321,6 @@ pub async fn hide() {
{
let _ = window.hide();
}
handle::Handle::global().set_activation_policy_accessory();
}
#[cfg(test)]
-3
View File
@@ -289,9 +289,6 @@ pub fn run() -> std::process::ExitCode {
}
pub fn handle_window_close(api: &tauri::WindowEvent) {
#[cfg(target_os = "macos")]
handle::Handle::global().set_activation_policy_accessory();
if core::handle::Handle::global().is_exiting() {
return;
}