mirror of
https://github.com/home-assistant/core.git
synced 2025-07-08 13:57:10 +00:00
Fix detection of client wan-access rule in AVM Fritz!Box Tools (#97708)
This commit is contained in:
parent
5e2d3b13b0
commit
c43e6d9bd1
@ -469,6 +469,11 @@ class FritzBoxTools(
|
|||||||
if not host.get("MACAddress"):
|
if not host.get("MACAddress"):
|
||||||
continue
|
continue
|
||||||
|
|
||||||
|
if (wan_access := host.get("X_AVM-DE_WANAccess")) is not None:
|
||||||
|
wan_access_result = "granted" in wan_access
|
||||||
|
else:
|
||||||
|
wan_access_result = None
|
||||||
|
|
||||||
hosts[host["MACAddress"]] = Device(
|
hosts[host["MACAddress"]] = Device(
|
||||||
name=host["HostName"],
|
name=host["HostName"],
|
||||||
connected=host["Active"],
|
connected=host["Active"],
|
||||||
@ -476,7 +481,7 @@ class FritzBoxTools(
|
|||||||
connection_type="",
|
connection_type="",
|
||||||
ip_address=host["IPAddress"],
|
ip_address=host["IPAddress"],
|
||||||
ssid=None,
|
ssid=None,
|
||||||
wan_access="granted" in host["X_AVM-DE_WANAccess"],
|
wan_access=wan_access_result,
|
||||||
)
|
)
|
||||||
|
|
||||||
if not self.fritz_status.device_has_mesh_support or (
|
if not self.fritz_status.device_has_mesh_support or (
|
||||||
|
Loading…
x
Reference in New Issue
Block a user