Fix TypeError for views (#1045)

* Fix TypeError for views

quick and dirty fix, maybe this file needs some more cleanup

problem:
if you have `default_view` in groups.yaml and reload groups in `computeViewStates(currentView, hass, defaultView)`
`defaultView` is (still) defined but but `hass.states.group.default_view` doesn't exist

Fix: #893

* Update partial-cards.html

* Add ;

* Lint
This commit is contained in:
c727 2018-04-01 02:35:33 +02:00 committed by Paulus Schoutsen
parent d7d167fbf9
commit 4c65767e5a

View File

@ -321,7 +321,8 @@
}
isView(currentView, defaultView) {
return currentView || defaultView;
return (currentView || defaultView) &&
this.hass.states[currentView || DEFAULT_VIEW_ENTITY_ID];
}
_defaultViewFilter(hass, entityId) {