diff options
| -rw-r--r-- | gui/src/renderer/app.tsx | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/gui/src/renderer/app.tsx b/gui/src/renderer/app.tsx index c37f52bd4f..c487f641ed 100644 --- a/gui/src/renderer/app.tsx +++ b/gui/src/renderer/app.tsx @@ -737,7 +737,12 @@ export default class AppRenderer { break; case 'disconnecting': - actions.connection.disconnecting(tunnelState.details); + if (tunnelState.details === 'reconnect') { + this.optimisticTunnelState = 'connecting'; + this.reduxActions.connection.connecting(); + } else { + actions.connection.disconnecting(tunnelState.details); + } break; case 'disconnected': @@ -750,7 +755,9 @@ export default class AppRenderer { } // Update the location when entering a new tunnel state since it's likely changed. - void this.updateLocation(); + void this.updateLocation( + this.optimisticTunnelState === undefined ? undefined : { state: this.optimisticTunnelState }, + ); } private setSettings(newSettings: ISettings) { |
