mirror of
https://github.com/actuallymentor/battery.git
synced 2026-02-03 14:03:24 +00:00
Merge pull request #53 from mineiwik/main
Replace hard-coded value when discharging
This commit is contained in:
@@ -175,7 +175,7 @@ const get_battery_status = async () => {
|
||||
|
||||
let battery_state = `${ percentage }% (${ remaining } remaining)`
|
||||
let daemon_state = ``
|
||||
if( discharging ) daemon_state += `forcing discharge to 80%`
|
||||
if( discharging ) daemon_state += `forcing discharge to ${ maintain_percentage || 80 }%`
|
||||
else daemon_state += `smc charging ${ charging ? 'enabled' : 'disabled' }`
|
||||
|
||||
const status_object = { percentage, remaining, charging, discharging, maintain_percentage, battery_state, daemon_state }
|
||||
|
||||
Reference in New Issue
Block a user