Fix stack trace in badge

This commit is contained in:
Paulus Schoutsen 2018-12-11 21:43:43 +01:00
parent 99395360c7
commit b1b78c2bb7

View File

@ -184,7 +184,7 @@ export class HaStateLabelBadge extends hassLocalizeLitMixin(LitElement) {
private startInterval(stateObj) {
this.clearInterval();
if (computeStateDomain(stateObj) === "timer") {
if (stateObj && computeStateDomain(stateObj) === "timer") {
this.calculateTimerRemaining(stateObj);
if (stateObj.state === "active") {