mirror of
https://github.com/home-assistant/core.git
synced 2025-07-19 11:17:21 +00:00
UniFi - Improve handling of client tracker is connected to better respect configured delay (#34510)
This commit is contained in:
parent
b73c774b07
commit
e004cd029a
@ -148,13 +148,6 @@ class UniFiClientTracker(UniFiClient, ScannerEntity):
|
|||||||
self.cancel_scheduled_update = None
|
self.cancel_scheduled_update = None
|
||||||
self.async_write_ha_state()
|
self.async_write_ha_state()
|
||||||
|
|
||||||
if (
|
|
||||||
not self.is_wired
|
|
||||||
and self.controller.option_ssid_filter
|
|
||||||
and self.client.essid not in self.controller.option_ssid_filter
|
|
||||||
):
|
|
||||||
return False
|
|
||||||
|
|
||||||
if (self.is_wired and self.wired_connection) or (
|
if (self.is_wired and self.wired_connection) or (
|
||||||
not self.is_wired and self.wireless_connection
|
not self.is_wired and self.wireless_connection
|
||||||
):
|
):
|
||||||
@ -174,6 +167,15 @@ class UniFiClientTracker(UniFiClient, ScannerEntity):
|
|||||||
dt_util.utcnow() + self.controller.option_detection_time,
|
dt_util.utcnow() + self.controller.option_detection_time,
|
||||||
)
|
)
|
||||||
|
|
||||||
|
if (
|
||||||
|
not self.is_wired
|
||||||
|
and self.client.essid
|
||||||
|
and self.controller.option_ssid_filter
|
||||||
|
and self.client.essid not in self.controller.option_ssid_filter
|
||||||
|
and not self.cancel_scheduled_update
|
||||||
|
):
|
||||||
|
return False
|
||||||
|
|
||||||
if self.is_disconnected is not None:
|
if self.is_disconnected is not None:
|
||||||
return not self.is_disconnected
|
return not self.is_disconnected
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user