Skip to content

Commit

Permalink
battery: always update status (fix perc) lcpz#199 lcpz#203
Browse files Browse the repository at this point in the history
  • Loading branch information
Luke Bonham committed Jun 9, 2016
1 parent 5547a49 commit f769402
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions widgets/bat.lua
Original file line number Diff line number Diff line change
Expand Up @@ -131,12 +131,12 @@ local function worker(args)

-- notifications for low and critical states
if notify == "on" and bat_now.perc and bat_now.status == "Discharging" then
if perc <= 5 then
if bat_now.perc <= 5 then
bat.id = naughty.notify({
preset = bat_notification_critical_preset,
replaces_id = bat.id
}).id
elseif perc <= 15 then
elseif bat_now.perc <= 15 then
bat.id = naughty.notify({
preset = bat_notification_low_preset,
replaces_id = bat.id
Expand Down

0 comments on commit f769402

Please sign in to comment.