mirror of
https://github.com/lxc/incus
synced 2026-08-01 21:25:31 +00:00
incusd/network/ovn: Skip empty transactions in SetChassisGroupPriority
Signed-off-by: Stéphane Graber <stgraber@stgraber.org>
This commit is contained in:
parent
54d230183c
commit
066ef03eb9
@ -2765,6 +2765,11 @@ func (o *NB) SetChassisGroupPriority(ctx context.Context, haChassisGroupName OVN
|
||||
operations = append(operations, updateOps...)
|
||||
}
|
||||
|
||||
// Skip the transaction if nothing changed.
|
||||
if len(operations) == 0 {
|
||||
return nil
|
||||
}
|
||||
|
||||
// Apply the changes.
|
||||
resp, err := o.client.Transact(ctx, operations...)
|
||||
if err != nil {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user