1
0
Fork 0

Handle wifi failure in panel

This commit is contained in:
Jeremy Kaplan 2017-07-04 18:35:58 -07:00
commit 7b2455cdfd

View file

@ -88,7 +88,7 @@ def wifi_update(_):
lines = [line.decode('utf-8') for line in info.splitlines()] lines = [line.decode('utf-8') for line in info.splitlines()]
active = [line[2:] for line in lines if line[0] == '*'] active = [line[2:] for line in lines if line[0] == '*']
if active: if active and ''.join(active) != 'FAIL':
interface, network = active[0].split('-', 1) interface, network = active[0].split('-', 1)
else: else:
interface, network = 'none', '-' interface, network = 'none', '-'