use startsWith

This commit is contained in:
Ludeeus 2021-02-16 17:11:09 +00:00
parent dbc3bc81a7
commit d9283c17eb

View File

@ -48,7 +48,7 @@ class HaMarkdownElement extends UpdatingElement {
node.host === "my.home-assistant.io"
) {
const hrefNodes = node.href.split("/");
if (document.location.pathname.includes("hassio")) {
if (document.location.pathname.startsWith("/hassio")) {
node.target = "_parent";
} else {
node.target = "_self";