Skip to content

Commit adfd894

Browse files
authored
Merge pull request #19 from Villhellm/title-change-option
null check for title element
2 parents 4dc5242 + 7b6aca0 commit adfd894

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

dist/custom-sidebar.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ function getSidebar() {
151151
root = root && root.querySelector("app-drawer-layout app-drawer");
152152
root = root && root.querySelector("ha-sidebar");
153153
root = root && root.shadowRoot;
154-
TitleElement = root.querySelector('span');
154+
TitleElement = root && root.querySelector('span') ? root.querySelector('span') : null ;
155155
root = root && root.querySelector("paper-listbox");
156156
return root;
157157
}

0 commit comments

Comments
 (0)