mirror of
https://github.com/home-assistant/core.git
synced 2025-07-27 07:07:28 +00:00
don't update state in turn_on/off
This commit is contained in:
parent
86b9ae9566
commit
12bdc39274
@ -64,7 +64,6 @@ class S20Switch(SwitchDevice):
|
|||||||
""" Turn the device on. """
|
""" Turn the device on. """
|
||||||
try:
|
try:
|
||||||
self._s20.on = True
|
self._s20.on = True
|
||||||
self._state = True
|
|
||||||
except S20Exception:
|
except S20Exception:
|
||||||
_LOGGER.exception("Error while turning on S20")
|
_LOGGER.exception("Error while turning on S20")
|
||||||
|
|
||||||
@ -72,6 +71,5 @@ class S20Switch(SwitchDevice):
|
|||||||
""" Turn the device off. """
|
""" Turn the device off. """
|
||||||
try:
|
try:
|
||||||
self._s20.on = False
|
self._s20.on = False
|
||||||
self._state = False
|
|
||||||
except S20Exception:
|
except S20Exception:
|
||||||
_LOGGER.exception("Error while turning off S20")
|
_LOGGER.exception("Error while turning off S20")
|
||||||
|
Loading…
x
Reference in New Issue
Block a user