There was an error while loading. Please reload this page.
1 parent d1dc0c6 commit 833b557Copy full SHA for 833b557
1 file changed
custom_components/mammotion/coordinator.py
@@ -807,10 +807,10 @@ async def _async_setup(self) -> None:
807
ota_info = await device.mammotion_http.get_device_ota_firmware(
808
[device.iot_id]
809
)
810
- if ota_info is not None:
811
- for check_version in ota_info.data:
812
- if check_version.device_id == device.iot_id:
813
- device.state.update_check = check_version
+ if check_versions := ota_info.data:
+ for check_version in check_versions:
+ if check_version.device_id == device.iot_id:
+ device.state.update_check = check_version
814
815
except DeviceOfflineException:
816
"""Device is offline bluetooth has been attempted."""
0 commit comments