Only add Netatmo climate schedule attribute if not None (#45176)

This commit is contained in:
Tobias Sauerwein
2021-01-15 13:15:59 +01:00
committed by GitHub
parent 41b45c7f78
commit b5690053a9

View File

@@ -417,7 +417,8 @@ class NetatmoThermostat(NetatmoBase, ClimateEntity):
"heating_power_request", 0
)
attr[ATTR_SELECTED_SCHEDULE] = self._selected_schedule
if self._selected_schedule is not None:
attr[ATTR_SELECTED_SCHEDULE] = self._selected_schedule
return attr