Files
openclaw/apps
Cihat Gündüz c3fba2bb20 fix(ios): forgetting a paired gateway does nothing (#114083)
* fix(ios): forgetting a paired gateway does nothing

Confirming "Forget Gateway" in Settings never removed the gateway. The
confirmation dialog derived its isPresented binding from the payload it
later needed and cleared that payload on dismissal, so by the time the
destructive button's action ran, forgetPendingGateway() found nil at its
opening guard and returned without calling forgetGateway(stableID:).
Nothing was logged either, because the failure branch was never reached.

Hand the entry to the action through the dialog's presenting: parameter
instead of reading it back from view state, and take it as a parameter
rather than looking it up. Everything downstream is unchanged; it simply
runs now.

* Shorten the dialog comment to one line

The three-line version repeated in prose what the next line already shows.
What is worth keeping is the trap: someone simplifying this back to reading
the entry from view state reintroduces the bug.

* fix(ios): harden forget gateway payload handoff

Co-authored-by: Cihat Gündüz <anthropic@fline.dev>

* test(ios): run gateway settings source guards

* test(ios): allow forget dialog state cleanup

* test(ci): provide rg in PR review fixture

---------

Co-authored-by: Cihat Gündüz <anthropic@fline.dev>
Co-authored-by: Peter Steinberger <steipete@gmail.com>
2026-07-28 09:59:23 -04:00
..