Skip to content

Commit

Permalink
fix cover state issue
Browse files Browse the repository at this point in the history
  • Loading branch information
regevbr authored and rospogrigio committed Oct 1, 2021
1 parent 5e71ee4 commit 6232762
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions custom_components/localtuya/cover.py
Original file line number Diff line number Diff line change
Expand Up @@ -109,9 +109,10 @@ def is_closed(self):
"""Return if the cover is closed or not."""
if self._config[CONF_POSITIONING_MODE] == COVER_MODE_NONE:
return None
elif self._current_cover_position == 0:

if self._current_cover_position == 0:
return True
elif self._current_cover_position == 100:
if self._current_cover_position == 100:
return False
return None

Expand Down

0 comments on commit 6232762

Please sign in to comment.