summaryrefslogtreecommitdiff
path: root/internal/client/ui/core/core.go
diff options
context:
space:
mode:
Diffstat (limited to 'internal/client/ui/core/core.go')
-rw-r--r--internal/client/ui/core/core.go2
1 files changed, 2 insertions, 0 deletions
diff --git a/internal/client/ui/core/core.go b/internal/client/ui/core/core.go
index 8c0a336..7e42619 100644
--- a/internal/client/ui/core/core.go
+++ b/internal/client/ui/core/core.go
@@ -388,6 +388,7 @@ func (m *Model) updateConnected(message tea.Msg) tea.Cmd {
} else {
log.Println("received error:", msg.Error)
gateway.Disconnect()
+ state.Reset()
return ui.Transition(ui.NewAuth())
}
}
@@ -490,6 +491,7 @@ func (m *Model) updateAuthenticated(message tea.Msg) tea.Cmd {
err := "new connection from another location, closing this one"
if err == msg.Error {
gateway.Disconnect()
+ state.Reset()
return ui.Transition(ui.NewAuth())
}