diff --git a/panel/panel_bar.py b/panel/panel_bar.py index 90a164c..e4234d2 100755 --- a/panel/panel_bar.py +++ b/panel/panel_bar.py @@ -104,7 +104,7 @@ def battery_update(_): info = subprocess.check_output(['acpi', '--battery']) info = info[:-1].decode('utf-8') - _, status = info.split(': ') + _, status = info.splitlines()[0].split(': ') state, charge, *_ = status.split(', ') state = state charge = int(charge[:-1])