macOS: keep Not configured from snapping back to remote

This commit is contained in:
Conrad 2026-01-26 22:53:06 -08:00
parent 6372242da7
commit 61a7f08e7b

View File

@ -533,6 +533,15 @@ final class AppState {
gateway["remote"] = remote
changed = true
}
} else if connectionMode == .unconfigured {
// Prevent implicit remote-mode re-selection when the user explicitly
// chooses "Not configured" in the UI. Leaving gateway.remote.url
// behind causes applyConfigOverrides to force .remote.
if var remote = gateway["remote"] as? [String: Any], remote["url"] != nil {
remote.removeValue(forKey: "url")
gateway["remote"] = remote
changed = true
}
}
guard changed else { return }