1
0
mirror of https://github.com/home-assistant/frontend.git synced 2025-12-24 20:55:49 +00:00

Fix for views with url starting with a number (#5176)

This commit is contained in:
Bram Kragten
2020-03-12 20:49:26 +01:00
committed by GitHub
parent d327045802
commit 785ae4a83d

View File

@@ -476,7 +476,7 @@ class HUIRoot extends LitElement {
newSelectView = "hass-unused-entities";
} else if (this._routeData!.view) {
const selectedView = this._routeData!.view;
const selectedViewInt = parseInt(selectedView, 10);
const selectedViewInt = Number(selectedView);
let index = 0;
for (let i = 0; i < views.length; i++) {
if (views[i].path === selectedView || i === selectedViewInt) {