Skip to content

Commit 08d92ab

Browse files
authored
Merge pull request #2752 from Nordix/update-golangci-lint-v2.5.0
🌱 Update golangci lint v2.5.0
2 parents 4364496 + 487d5a2 commit 08d92ab

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

hack/tools/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
ROOT_DIR_RELATIVE := ../..
1616
include $(ROOT_DIR_RELATIVE)/common.mk
1717

18-
GOLANGCI_LINT_VERSION ?= v2.4.0
18+
GOLANGCI_LINT_VERSION ?= v2.5.0
1919

2020
# GOTESTSUM version without the leading 'v'
2121
GOTESTSUM_VERSION ?= 1.12.0

pkg/cloud/services/compute/instance.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -241,14 +241,14 @@ func (s *Service) getOrCreateVolumeBuilder(eventObject runtime.Object, instanceS
241241

242242
func resolveVolumeOpts(instanceSpec *InstanceSpec, volumeOpts *infrav1.BlockDeviceVolume) (az, volType string) {
243243
if volumeOpts == nil {
244-
return
244+
return az, volType
245245
}
246246

247247
volType = volumeOpts.Type
248248

249249
volumeAZ := volumeOpts.AvailabilityZone
250250
if volumeAZ == nil {
251-
return
251+
return az, volType
252252
}
253253

254254
switch volumeAZ.From {
@@ -260,7 +260,7 @@ func resolveVolumeOpts(instanceSpec *InstanceSpec, volumeOpts *infrav1.BlockDevi
260260
case infrav1.VolumeAZFromMachine:
261261
az = instanceSpec.FailureDomain
262262
}
263-
return
263+
return az, volType
264264
}
265265

266266
// getBlockDevices returns a list of block devices that were created and attached to the instance. It returns an error

pkg/utils/filterconvert/convert.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ func RouterFilterToListOpts(routerFilter *infrav1.RouterFilter) routers.ListOpts
9393

9494
func ImageFilterToListOpts(imageFilter *infrav1.ImageFilter) (listOpts images.ListOpts) {
9595
if imageFilter == nil {
96-
return
96+
return listOpts
9797
}
9898

9999
if imageFilter.Name != nil && *imageFilter.Name != "" {
@@ -103,5 +103,5 @@ func ImageFilterToListOpts(imageFilter *infrav1.ImageFilter) (listOpts images.Li
103103
if len(imageFilter.Tags) > 0 {
104104
listOpts.Tags = imageFilter.Tags
105105
}
106-
return
106+
return listOpts
107107
}

0 commit comments

Comments
 (0)