From 66ab1acf4d98d2544776f84eaf0d2bd9e00fa2cf Mon Sep 17 00:00:00 2001 From: Josef Zweck <24647999+zweckj@users.noreply.github.com> Date: Fri, 11 Aug 2023 07:25:49 +0200 Subject: [PATCH] revert last changes --- custom_components/lamarzocco/coordinator.py | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/custom_components/lamarzocco/coordinator.py b/custom_components/lamarzocco/coordinator.py index 5d9d9a8..8e29e82 100644 --- a/custom_components/lamarzocco/coordinator.py +++ b/custom_components/lamarzocco/coordinator.py @@ -42,7 +42,6 @@ def __init__(self, hass, config_entry, lm): self._websocket_task = None self._config_entry = config_entry self._use_websocket = self._config_entry.options.get(CONF_USE_WEBSOCKET, True) - self._brew_running_set = False async def _async_update_data(self): try: @@ -94,15 +93,6 @@ def _on_data_received(self, property_updated, update): self.data = self._lm - # machine spams the websocket with brew_active updates, during brew - # so we only want to update the listeners once, to avoid overloading HA - if property_updated == BREW_ACTIVE and update and not self._brew_running_set: - self._brew_running_set = True - elif property_updated == BREW_ACTIVE and update and self._brew_running_set: - return - elif property_updated == BREW_ACTIVE and not update: - self._brew_running_set = False - self.async_update_listeners() def terminate_websocket(self):