Skip to content

Locations 0.1.3: Leaving an address field no longer wipes the form

Locations 0.1.3 fixes a crash on the location form of the PhoenixKit locations module that threw away everything you had typed.

When you left the address, city or postal code field, the form checked whether another location already has a similar address. That check expected the whole form’s data, but leaving a field sends only that field. Every time, the page crashed, reconnected and came back with the fields you had filled in empty.

The check now reads the address from the form’s current state. Leaving a field keeps your input, and the Similar address found at: warning works as intended.

Full release notes: Locations 0.1.3

0.1.3 · 25 May 2026

Fixed

  • check_address no longer crashes the location form’s LiveView on address-field blur. phx-blur delivers %{"key", "value"}, not the form’s serialized params, so the old %{"location" => params} clause never matched and every blur raised FunctionClauseError — taking down the LiveView, forcing a reconnect, and wiping every in-progress field. The handler now reads the address from the changeset (kept current by phx-change="validate").

Quality

  • check_address tests now drive the real phx-blur event via render_blur on the input element instead of a hand-crafted render_hook payload, plus a regression test asserting the LiveView survives a blur and preserves typed fields.

Locations 0.1.3. Install or update: {:phoenix_kit_locations, "~> 0.1"}, then mix deps.get && mix phoenix_kit.update. Full history: CHANGELOG.