mirror of
https://github.com/outbackdingo/firezone.git
synced 2026-01-27 10:18:54 +00:00
fix(gui-client): stop telemetry in tunnel service on disconnect (#9765)
In order to re-initialise telemetry on a new session, we need to make sure it is de-initialised on every session disconnect.
This commit is contained in:
@@ -456,6 +456,7 @@ impl<'a> Handler<'a> {
|
||||
match msg {
|
||||
client_shared::Event::Disconnected(error) => {
|
||||
self.session = Session::None;
|
||||
self.telemetry.stop_on_crash().await;
|
||||
self.dns_controller.deactivate()?;
|
||||
self.send_ipc(ServerMsg::OnDisconnect {
|
||||
error_msg: error.to_string(),
|
||||
@@ -526,6 +527,7 @@ impl<'a> Handler<'a> {
|
||||
}
|
||||
ClientMsg::Disconnect => {
|
||||
self.session = Session::None;
|
||||
self.telemetry.stop().await;
|
||||
self.dns_controller.deactivate()?;
|
||||
|
||||
// Always send `DisconnectedGracefully` even if we weren't connected,
|
||||
|
||||
Reference in New Issue
Block a user