mirror of
https://github.com/rembo10/headphones.git
synced 2026-05-02 09:49:36 +01:00
Check _if_ WebUI daemons exist before checking _how many_ exist, fix #3010
This commit is contained in:
@@ -379,7 +379,8 @@ def _get_auth():
|
|||||||
return None
|
return None
|
||||||
|
|
||||||
delugeweb_hosts = json.loads(response.text)['result']
|
delugeweb_hosts = json.loads(response.text)['result']
|
||||||
if len(delugeweb_hosts) == 0:
|
# Check if delugeweb_hosts is None before checking its length
|
||||||
|
if not delugeweb_hosts or len(delugeweb_hosts) == 0:
|
||||||
logger.error('Deluge: WebUI does not contain daemons')
|
logger.error('Deluge: WebUI does not contain daemons')
|
||||||
return None
|
return None
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user