Skip to content

Commit 1792c45

Browse files
authored
fix(core): run setup after preparing system tray (#2312)
* fix(core): run setup after preparing system tray * change file [skip ci]
1 parent 05e679a commit 1792c45

File tree

2 files changed

+7
-2
lines changed

2 files changed

+7
-2
lines changed

Diff for: .changes/setup-fix.md

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"tauri": patch
3+
---
4+
5+
Run the setup callback after preparing the system tray.

Diff for: core/tauri/src/app.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -822,8 +822,6 @@ impl<R: Runtime> Builder<R> {
822822
}
823823
}
824824

825-
(self.setup)(&mut app).map_err(|e| crate::Error::Setup(e))?;
826-
827825
#[cfg(feature = "system-tray")]
828826
if let Some(system_tray) = self.system_tray {
829827
let mut ids = HashMap::new();
@@ -894,6 +892,8 @@ impl<R: Runtime> Builder<R> {
894892
}
895893
}
896894

895+
(self.setup)(&mut app).map_err(|e| crate::Error::Setup(e))?;
896+
897897
#[cfg(feature = "updater")]
898898
app.run_updater(main_window);
899899

0 commit comments

Comments
 (0)