powerd: Adding case for devices that ignore power

This adds a condition that permits updates for devices that don't take
any power conditions into account.
This commit is contained in:
George Popoola 2021-07-22 16:32:36 +00:00 committed by Richard Hughes
parent 4b10b1324c
commit 1d8d26d167

View File

@ -87,6 +87,10 @@ fu_plugin_update_prepare (FuPlugin *plugin,
return FALSE;
}
/* permit updates when the device does not care about power conditions */
if (flags & FWUPD_INSTALL_FLAG_IGNORE_POWER)
return TRUE;
/* parse and use for battery-check conditions */
g_variant_get (powerd_response,
"(uud)",