From f38b0b26709621a33a53c470140db60d7e719e65 Mon Sep 17 00:00:00 2001 From: sti0 Date: Fri, 28 Jun 2024 18:09:04 +0000 Subject: [PATCH] fix await coroutine --- custom_components/stiebel_eltron_isg/number.py | 2 +- custom_components/stiebel_eltron_isg/select.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/custom_components/stiebel_eltron_isg/number.py b/custom_components/stiebel_eltron_isg/number.py index fed3b04..0bf884f 100644 --- a/custom_components/stiebel_eltron_isg/number.py +++ b/custom_components/stiebel_eltron_isg/number.py @@ -247,7 +247,7 @@ def unique_id(self) -> str | None: async def async_set_native_value(self, value: float) -> None: """Set new value.""" - self.coordinator.set_data(self.entity_description.key, value) + await self.coordinator.set_data(self.entity_description.key, value) @property def native_value(self): diff --git a/custom_components/stiebel_eltron_isg/select.py b/custom_components/stiebel_eltron_isg/select.py index cb5259b..7cf9267 100644 --- a/custom_components/stiebel_eltron_isg/select.py +++ b/custom_components/stiebel_eltron_isg/select.py @@ -106,7 +106,7 @@ def current_option(self): async def async_select_option(self, option: str) -> None: """Update the current selected option.""" key = get_key_from_value(self._options, option) - self.coordinator.set_data(self.entity_description.key, key) + await self.coordinator.set_data(self.entity_description.key, key) @property def available(self) -> bool: