Skip to content

Commit ebe3255

Browse files
authored
Merge pull request kubernetes#77297 from humblec/fakeclient-csi
Correct errors and remove unwanted code blocks .
2 parents b219272 + 4d56ab1 commit ebe3255

File tree

4 files changed

+5
-6
lines changed

4 files changed

+5
-6
lines changed

pkg/controller/garbagecollector/graph_builder.go

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -180,9 +180,8 @@ func (gb *GraphBuilder) controllerFor(resource schema.GroupVersionResource, kind
180180
// need to clone because it's from a shared cache
181181
shared.Informer().AddEventHandlerWithResyncPeriod(handlers, ResourceResyncTime)
182182
return shared.Informer().GetController(), shared.Informer().GetStore(), nil
183-
} else {
184-
klog.V(4).Infof("unable to use a shared informer for resource %q, kind %q: %v", resource.String(), kind.String(), err)
185183
}
184+
klog.V(4).Infof("unable to use a shared informer for resource %q, kind %q: %v", resource.String(), kind.String(), err)
186185

187186
// TODO: consider store in one storage.
188187
klog.V(5).Infof("create storage for resource %s", resource)

pkg/volume/csi/csi_plugin.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -765,7 +765,7 @@ func (p *csiPlugin) ConstructBlockVolumeSpec(podUID types.UID, specVolName, mapP
765765
}
766766

767767
// skipAttach looks up CSIDriver object associated with driver name
768-
// to determine if driver requies attachment volume operation
768+
// to determine if driver requires attachment volume operation
769769
func (p *csiPlugin) skipAttach(driver string) (bool, error) {
770770
if !utilfeature.DefaultFeatureGate.Enabled(features.CSIDriverRegistry) {
771771
return false, nil

pkg/volume/csi/csi_plugin_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -366,7 +366,7 @@ func TestPluginConstructVolumeSpec(t *testing.T) {
366366
t.Fatal(err)
367367
}
368368
if spec == nil {
369-
t.Fatal("nil volume.Spec contstructed")
369+
t.Fatal("nil volume.Spec constructed")
370370
}
371371

372372
// inspect spec
@@ -474,7 +474,7 @@ func TestPluginConstructVolumeSpecWithInline(t *testing.T) {
474474
t.Fatal(err)
475475
}
476476
if spec == nil {
477-
t.Fatal("nil volume.Spec contstructed")
477+
t.Fatal("nil volume.Spec constructed")
478478
}
479479

480480
if spec.Name() != tc.specVolID {

pkg/volume/plugins.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -842,7 +842,7 @@ func (pm *VolumePluginMgr) FindProvisionablePluginByName(name string) (Provision
842842
return nil, fmt.Errorf("no provisionable volume plugin matched")
843843
}
844844

845-
// FindDeletablePluginBySppec fetches a persistent volume plugin by spec. If
845+
// FindDeletablePluginBySpec fetches a persistent volume plugin by spec. If
846846
// no plugin is found, returns error.
847847
func (pm *VolumePluginMgr) FindDeletablePluginBySpec(spec *Spec) (DeletableVolumePlugin, error) {
848848
volumePlugin, err := pm.FindPluginBySpec(spec)

0 commit comments

Comments
 (0)