Skip to content

Commit

Permalink
Merge pull request #1068 from atc0005/fix-unused-parameter-revive-lin…
Browse files Browse the repository at this point in the history
…ting-errors

Fix `unused-parameter` revive linting errors
  • Loading branch information
atc0005 authored Feb 13, 2024
2 parents c682b0d + e7af99e commit e8adbda
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions cmd/check_vmware_hs2ds2vms/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -301,9 +301,9 @@ func main() {
hostID, pairing := hostID, pairing

dsNamesForHost := func(pairings vsphere.HostDatastoresPairing) string {
names := make([]string, len(pairing.Datastores))
for i := range pairing.Datastores {
names[i] = pairing.Datastores[i].Name
names := make([]string, len(pairings.Datastores))
for i := range pairings.Datastores {
names[i] = pairings.Datastores[i].Name
}
return strings.Join(names, ", ")
}(pairing)
Expand Down
2 changes: 1 addition & 1 deletion internal/vsphere/snapshots.go
Original file line number Diff line number Diff line change
Expand Up @@ -868,7 +868,7 @@ func ListVMSnapshots(vm mo.VirtualMachine, w io.Writer) {

var listFunc func(mo.VirtualMachine, []types.VirtualMachineSnapshotTree, *types.ManagedObjectReference)

listFunc = func(vm mo.VirtualMachine, snapTrees []types.VirtualMachineSnapshotTree, parent *types.ManagedObjectReference) {
listFunc = func(vm mo.VirtualMachine, snapTrees []types.VirtualMachineSnapshotTree, _ *types.ManagedObjectReference) {

if len(snapTrees) == 0 {
return
Expand Down
2 changes: 1 addition & 1 deletion internal/vsphere/vms.go
Original file line number Diff line number Diff line change
Expand Up @@ -1261,7 +1261,7 @@ func getVMsCountUsingRootFolderContainerView(
logger.Printf(
"It took %v to execute getVMsCountUsingRootFolderContainerView func (and count %d VMs).\n",
time.Since(funcTimeStart),
len(allVMs),
len(*vms),
)
}(&allVMs)

Expand Down

0 comments on commit e8adbda

Please sign in to comment.