From 154fe8631a3604054e2297950a9099d484be7645 Mon Sep 17 00:00:00 2001 From: starkillerOG Date: Thu, 18 Jan 2024 03:34:18 +0100 Subject: [PATCH] Use cache update for WIFI blinds (#108224) --- homeassistant/components/motion_blinds/coordinator.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/homeassistant/components/motion_blinds/coordinator.py b/homeassistant/components/motion_blinds/coordinator.py index cfc7d319b38..e8dc5494f25 100644 --- a/homeassistant/components/motion_blinds/coordinator.py +++ b/homeassistant/components/motion_blinds/coordinator.py @@ -5,7 +5,7 @@ import logging from socket import timeout from typing import Any -from motionblinds import ParseException +from motionblinds import DEVICE_TYPES_WIFI, ParseException from homeassistant.core import HomeAssistant from homeassistant.helpers.update_coordinator import DataUpdateCoordinator @@ -59,7 +59,9 @@ class DataUpdateCoordinatorMotionBlinds(DataUpdateCoordinator): def update_blind(self, blind): """Fetch data from a blind.""" try: - if self._wait_for_push: + if blind.device_type in DEVICE_TYPES_WIFI: + blind.Update_from_cache() + elif self._wait_for_push: blind.Update() else: blind.Update_trigger()