Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions app/src-tauri/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -176,6 +176,15 @@ async fn updater_install(
)
.await
.map_err(|e| e.to_string())?;
// Kill the node sidecar before relaunching; restart() may not run the Exit
// handler, and a lingering server would hold port 34115 and break the new
// instance's own sidecar.
#[cfg(not(debug_assertions))]
if let Some(state) = app.try_state::<ServerChild>() {
if let Some(child) = state.0.lock().unwrap().take() {
let _ = child.kill();
}
}
app.restart()
}

Expand Down
Loading