Check supported func properly

This commit is contained in:
Paulus Schoutsen 2019-06-30 23:03:51 -07:00
parent ed7b81e7a4
commit 8c1aff7505

View File

@ -287,7 +287,7 @@ class HaSidebar extends LitElement {
if (changedProps.has("alwaysExpand")) {
this.expanded = this.alwaysExpand;
}
if (SUPPORT_SCROLL_IF_NEEDED && !changedProps.has("hass")) {
if (SUPPORT_SCROLL_IF_NEEDED || !changedProps.has("hass")) {
return;
}
const oldHass = changedProps.get("hass") as HomeAssistant | undefined;