Skip to content

Commit

Permalink
Don't try to update activities if http call failed
Browse files Browse the repository at this point in the history
  • Loading branch information
mattgruter committed Nov 2, 2023
1 parent 785a846 commit 35f1f45
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion custom_components/unfoldedcircle/remote.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,9 @@ async def async_update(self) -> None:
_LOGGER.exception(
"Error retrieving data from UnfoldedCircle device %s", self.name
)
self._attr_activity_list = [a["name"]["en"] for a in activities]
self._available = False
else:
self._attr_activity_list = [a["name"]["en"] for a in activities]

async def async_send_command(self, command, **kwargs) -> None:
"""Send commands to a device."""
Expand Down

0 comments on commit 35f1f45

Please sign in to comment.