Skip to content

Commit

Permalink
Avoid locally scoped variable issue.
Browse files Browse the repository at this point in the history
Signed-off-by: Jacob Anders <[email protected]>
  • Loading branch information
rhjanders committed Oct 16, 2024
1 parent b4a2ace commit ab81282
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion controllers/metal3.io/baremetalhost_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -1386,7 +1386,9 @@ func (r *BareMetalHostReconciler) checkServicing(prov provisioner.Provisioner, i
}

if servicingData.LiveFirmwareSettingsAllowed {
hfsDirty, hfs, err := r.getHostFirmwareSettings(info)
var hfs *metal3api.HostFirmwareSettings
var err error
hfsDirty, hfs, err = r.getHostFirmwareSettings(info)
if err != nil {
return actionError{fmt.Errorf("could not determine updated settings: %w", err)}, false
}
Expand Down

0 comments on commit ab81282

Please sign in to comment.