mirror of
https://git.proxmox.com/git/fwupd
synced 2025-07-27 12:54:58 +00:00
trivial: Do not return failure if a device flag is already set
If we have multiple versions of upgrades/downgrades we'll be setting the REPORTED flags for multiple history entries at once.
This commit is contained in:
parent
1a24d9da90
commit
ee7e764603
@ -630,13 +630,8 @@ fu_engine_modify_device (FuEngine *self,
|
||||
"key %s not a valid flag", key);
|
||||
return FALSE;
|
||||
}
|
||||
if (fu_device_has_flag (device, flag)) {
|
||||
g_set_error_literal (error,
|
||||
FWUPD_ERROR,
|
||||
FWUPD_ERROR_NOT_SUPPORTED,
|
||||
"device already has that flag");
|
||||
return FALSE;
|
||||
}
|
||||
if (fu_device_has_flag (device, flag))
|
||||
return TRUE;
|
||||
if (flag != FWUPD_DEVICE_FLAG_REPORTED &&
|
||||
flag != FWUPD_DEVICE_FLAG_NOTIFIED) {
|
||||
g_set_error (error,
|
||||
|
Loading…
Reference in New Issue
Block a user