Skip to content

Commit

Permalink
Tahoma seems to not send all possible keys, depending on the devices …
Browse files Browse the repository at this point in the history
…states, we should add the unknown key instead of raising an error.
  • Loading branch information
vlebourl committed Jun 12, 2020
1 parent b2a7710 commit 6e9c03b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion custom_components/tahoma/tahoma_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -650,7 +650,7 @@ def active_states(self):
def set_active_state(self, name, value):
"""Set active state."""
if name not in self.__active_states.keys():
raise ValueError("Can not set unknown state '" + name + "'")
self.__active_states[name] = value

if (isinstance(self.__active_states[name], int) and
isinstance(value, str)):
Expand Down

0 comments on commit 6e9c03b

Please sign in to comment.