Skip to content

Commit

Permalink
Fix typo in Battery.cpp
Browse files Browse the repository at this point in the history
When the limit is valid, use the actual configured limit, not the bool value :)
  • Loading branch information
ranma authored and AndreasBoehm committed Oct 10, 2024
1 parent 2454cea commit 28c0c9d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Battery.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ float BatteryClass::getDischargeCurrentLimit()
}

if (dischargeCurrentValid) {
return dischargeCurrentValid;
return dischargeCurrentLimit;
}

return FLT_MAX;
Expand Down

0 comments on commit 28c0c9d

Please sign in to comment.