mirror of
https://github.com/home-assistant/core.git
synced 2025-07-23 13:17:32 +00:00
Fix Swisscom empty response received (#28782)
This commit is contained in:
parent
60e7440ec1
commit
4c690eace8
@ -92,6 +92,10 @@ class SwisscomDeviceScanner(DeviceScanner):
|
|||||||
_LOGGER.info("No response from Swisscom Internet Box")
|
_LOGGER.info("No response from Swisscom Internet Box")
|
||||||
return devices
|
return devices
|
||||||
|
|
||||||
|
if "status" not in request.json():
|
||||||
|
_LOGGER.info("No status in response from Swisscom Internet Box")
|
||||||
|
return devices
|
||||||
|
|
||||||
for device in request.json()["status"]:
|
for device in request.json()["status"]:
|
||||||
try:
|
try:
|
||||||
devices[device["Key"]] = {
|
devices[device["Key"]] = {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user