Skip to content

Commit

Permalink
Fixed issue when inside temperature is unavailable
Browse files Browse the repository at this point in the history
  • Loading branch information
sockless-coding committed Jul 21, 2022
1 parent 7479f3b commit 8ffcf31
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions custom_components/panasonic_cc/climate.py
Original file line number Diff line number Diff line change
Expand Up @@ -135,12 +135,12 @@ def hvac_action(self):
hvac_mode = self.hvac_mode
if (
(hvac_mode == HVACMode.HEAT or hvac_mode == HVACMode.HEAT_COOL)
and self._api.target_temperature > self._api.inside_temperature
and (self._api.inside_temperature is None or self._api.target_temperature > self._api.inside_temperature)
):
return HVACAction.HEATING
elif (
(hvac_mode == HVACMode.COOL or hvac_mode == HVACMode.HEAT_COOL)
and self._api.target_temperature < self._api.inside_temperature
and (self._api.inside_temperature is None or self._api.target_temperature < self._api.inside_temperature)
):
return HVACAction.COOLING
elif hvac_mode == HVACMode.DRY:
Expand Down

0 comments on commit 8ffcf31

Please sign in to comment.