Skip to content

Commit

Permalink
🐛 Fix humidity sensor creation. Fixes Humidity sensor is wrongly impo…
Browse files Browse the repository at this point in the history
…rted #56
  • Loading branch information
anarion80 committed Mar 16, 2024
1 parent f9c9970 commit 1702233
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion custom_components/tech/climate.py
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ def update_properties(self, device):
self._temperature = None

# Update humidity
if device[CONF_ZONE]["humidity"] is not None:
if device[CONF_ZONE]["humidity"] is not None and device[CONF_ZONE]["humidity"] >= 0:
self._humidity = device[CONF_ZONE]["humidity"]
else:
self._humidity = None
Expand Down
2 changes: 1 addition & 1 deletion custom_components/tech/sensor.py
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,7 @@ def is_humidity_operating_device(device) -> bool:
"""
return (
device[CONF_ZONE]["humidity"] is not None and device[CONF_ZONE]["humidity"] != 0
device[CONF_ZONE]["humidity"] is not None and device[CONF_ZONE]["humidity"] >= 0
)


Expand Down

0 comments on commit 1702233

Please sign in to comment.