Skip to content

Commit

Permalink
Fix mac 100% bug
Browse files Browse the repository at this point in the history
  • Loading branch information
tomcobley committed Jun 21, 2020
1 parent 287c8bd commit 49b4af4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion sys.c
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ void read_battery_info__macos(battery_t *battery, FILE *batteryinfo) {
strcpy(status, skip_white_space(str_ptr));

// initiliase battery struct using information from system
if (strcmp(status, "fully-charged") == 0 || strcmp(status, "charging") == 0) {
if (strcmp(status, "fully-charged") == 0 || strcmp(status, "charged") == 0 || strcmp(status, "charging") == 0) {
update_battery(battery, CHARGING, percentage);
} else {
// battery is either "discharging" or "AC attached; not charging"
Expand Down

0 comments on commit 49b4af4

Please sign in to comment.