Fixed being unable to resume from pause-on-battery

Fixes #3041
This commit is contained in:
SChernykh 2022-05-05 21:13:02 +02:00
parent 1ae9a4e428
commit 6793981066

View file

@ -515,7 +515,7 @@ void xmrig::Miner::setEnabled(bool enabled)
return;
}
if (d_ptr->battery_power && enabled) {
if (d_ptr->controller->config()->isPauseOnBattery() && d_ptr->battery_power && enabled) {
LOG_INFO("%s " YELLOW_BOLD("can't resume while on battery power"), Tags::miner());
return;