Compare commits

...

1 Commits

Author SHA1 Message Date
Thomas Lovén
813c9014e5 Avoid error in map-card 2021-05-20 16:18:31 +02:00

View File

@@ -297,7 +297,7 @@ class HuiMapCard extends LitElement implements LovelaceCard {
private async loadMap(): Promise<void> {
[this._leafletMap, this.Leaflet, this._tileLayer] = await setupLeafletMap(
this._mapEl,
this._config!.dark_mode ?? this.hass.themes.darkMode
this._config?.dark_mode ?? this.hass.themes.darkMode
);
this._drawEntities();
this._leafletMap.invalidateSize();