Fix firmware status check for Fritz (#59578)

This commit is contained in:
Simone Chemelli 2021-11-12 19:09:03 +01:00 committed by GitHub
parent 44ae0e214a
commit 4cfac18e1a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -257,10 +257,10 @@ class FritzBoxTools:
def _update_device_info(self) -> tuple[bool, str | None]:
"""Retrieve latest device information from the FRITZ!Box."""
userinterface = self.connection.call_action("UserInterface1", "GetInfo")
return userinterface.get("NewUpgradeAvailable"), userinterface.get(
version = self.connection.call_action("UserInterface1", "GetInfo").get(
"NewX_AVM-DE_Version"
)
return bool(version), version
def scan_devices(self, now: datetime | None = None) -> None:
"""Scan for new devices and return a list of found device ids."""