1
0
mirror of https://github.com/home-assistant/frontend.git synced 2026-04-02 00:27:49 +01:00

Fix gallery integration card crash from invalid mock hassUrl (#30126)

The gallery mock set hass.auth.data.hassUrl to an empty string, which
caused brandsUrl() to throw when constructing a URL via new URL(base, '').
In production hassUrl is always a valid URL, so the mock now uses
location.origin to match real behavior.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This commit is contained in:
Logan Rosen
2026-03-13 02:27:39 -04:00
committed by GitHub
parent 95a7b91ea5
commit 3bb870f52a

View File

@@ -196,7 +196,7 @@ export const provideHass = (
// Home Assistant properties
auth: {
data: {
hassUrl: "",
hassUrl: location.origin,
},
} as any,
connection: {