Skip to content

Commit b9606be

Browse files
authored
Merge pull request kubernetes#76860 from SataQiu/fix-golint-volume-20190420
Fix golint failures of pkg/volume/local
2 parents 33f907a + 1f40880 commit b9606be

File tree

2 files changed

+7
-8
lines changed

2 files changed

+7
-8
lines changed

hack/.golint_failures

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -347,7 +347,6 @@ pkg/volume/csi/fake
347347
pkg/volume/git_repo
348348
pkg/volume/host_path
349349
pkg/volume/iscsi
350-
pkg/volume/local
351350
pkg/volume/nfs
352351
pkg/volume/photon_pd
353352
pkg/volume/portworx

pkg/volume/local/local.go

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ const (
4242
defaultFSType = "ext4"
4343
)
4444

45-
// This is the primary entrypoint for volume plugins.
45+
// ProbeVolumePlugins is the primary entrypoint for volume plugins.
4646
func ProbeVolumePlugins() []volume.VolumePlugin {
4747
return []volume.VolumePlugin{&localVolumePlugin{}}
4848
}
@@ -587,15 +587,15 @@ func (u *localVolumeUnmapper) TearDownDevice(mapPath, _ string) error {
587587

588588
// GetGlobalMapPath returns global map path and error.
589589
// path: plugins/kubernetes.io/kubernetes.io/local-volume/volumeDevices/{volumeName}
590-
func (lv *localVolume) GetGlobalMapPath(spec *volume.Spec) (string, error) {
591-
return filepath.Join(lv.plugin.host.GetVolumeDevicePluginDir(utilstrings.EscapeQualifiedName(localVolumePluginName)),
592-
lv.volName), nil
590+
func (l *localVolume) GetGlobalMapPath(spec *volume.Spec) (string, error) {
591+
return filepath.Join(l.plugin.host.GetVolumeDevicePluginDir(utilstrings.EscapeQualifiedName(localVolumePluginName)),
592+
l.volName), nil
593593
}
594594

595595
// GetPodDeviceMapPath returns pod device map path and volume name.
596596
// path: pods/{podUid}/volumeDevices/kubernetes.io~local-volume
597597
// volName: local-pv-ff0d6d4
598-
func (lv *localVolume) GetPodDeviceMapPath() (string, string) {
599-
return lv.plugin.host.GetPodVolumeDeviceDir(lv.podUID,
600-
utilstrings.EscapeQualifiedName(localVolumePluginName)), lv.volName
598+
func (l *localVolume) GetPodDeviceMapPath() (string, string) {
599+
return l.plugin.host.GetPodVolumeDeviceDir(l.podUID,
600+
utilstrings.EscapeQualifiedName(localVolumePluginName)), l.volName
601601
}

0 commit comments

Comments
 (0)