Skip to content

Commit

Permalink
fix(lint): avoid some lint errors about deprecated fields
Browse files Browse the repository at this point in the history
Signed-off-by: James Munson <james.munson@suse.com>
  • Loading branch information
james-munson authored and ejweber committed Aug 16, 2024
1 parent 4702135 commit 57aece3
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions controller/instance_manager_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -940,14 +940,14 @@ func formatInstanceMessage(im *longhorn.InstanceManager) string {
}
}

if len(im.Status.Instances) > 0 {
if len(im.Status.Instances) > 0 { // nolint: staticcheck
if ieFormated {
msg = fmt.Sprintf("%v Instances count %v", msg, len(im.Status.Instances))
msg = fmt.Sprintf("%v Instances count %v", msg, len(im.Status.Instances)) // nolint: staticcheck
} else {
msg = fmt.Sprintf("Instances count %v", len(im.Status.Instances))
msg = fmt.Sprintf("Instances count %v", len(im.Status.Instances)) // nolint: staticcheck
}
i := 0
for k := range im.Status.Instances {
for k := range im.Status.Instances { // nolint: staticcheck
msg = msg + " " + k
if i++; i >= ITERATE_NAME_LIMIT {
break
Expand Down

0 comments on commit 57aece3

Please sign in to comment.