Skip to content

PhoenixKit 2.12.1: Two sitemap fixes for multi-domain sites

PhoenixKit 2.12.1 fixes two sitemap problems that came with 2.12.0.

On a site with a domain per language, the primary domain’s sitemap could list its home page twice. This happened when the primary domain’s language was not the site’s default language, and the default language had no domain of its own. The primary domain’s own language now keeps that address, and the duplicate is dropped.

A single invalid entry in the sitemap_non_page_pipelines setting, such as a number among the pipeline names, removed every route found in the router from the sitemap, with nothing in the log. Invalid entries are now ignored and the valid ones still apply. The same goes for sitemap_protected_pipelines.

Full release notes: PhoenixKit 2.12.1

2.12.1 · 17 August 2026

Two defects in the sitemap domain-mode code that landed with 2.12.0, found by reviewing that release’s own follow-up commits after it shipped (#731).

Fixed

  • Duplicate <loc> on the primary sitemap domain. When the primary domain hosts a language that is NOT the site default, and the site default has no domain of its own, the default language’s unprefixed home page re-hosted onto exactly the URL the primary’s own language already occupied — the same URL twice in one file. The host’s own language now wins its URL and the colliding domainless entry is dropped (#731).
  • One junk element in sitemap_non_page_pipelines emptied the whole router-discovery source, silently. A hand-edited settings value like ["phoenix_kit_api", 1] raised inside safe_to_atom/1, which collect/1’s rescue swallowed — removing every discovered route from the sitemap with nothing in the log. Junk elements are now ignored while the good ones still apply; this also hardens sitemap_protected_pipelines, which shares the same helper (#731).

PhoenixKit 2.12.1. Install or update: {:phoenix_kit, "~> 2.12"}, then mix deps.get && mix phoenix_kit.update. Full history: CHANGELOG.