File tree 2 files changed +6
-0
lines changed
pkg/controller/volume/attachdetach/cache
2 files changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -287,6 +287,9 @@ func (asw *actualStateOfWorld) AddVolumeNode(
287
287
}
288
288
attachableVolumePlugin , err := asw .volumePluginMgr .FindAttachablePluginBySpec (volumeSpec )
289
289
if err != nil || attachableVolumePlugin == nil {
290
+ if attachableVolumePlugin == nil {
291
+ err = fmt .Errorf ("plugin do not support attachment" )
292
+ }
290
293
return "" , fmt .Errorf (
291
294
"failed to get AttachablePlugin from volumeSpec for volume %q err=%v" ,
292
295
volumeSpec .Name (),
Original file line number Diff line number Diff line change @@ -225,6 +225,9 @@ func (dsw *desiredStateOfWorld) AddPod(
225
225
226
226
attachableVolumePlugin , err := dsw .volumePluginMgr .FindAttachablePluginBySpec (volumeSpec )
227
227
if err != nil || attachableVolumePlugin == nil {
228
+ if attachableVolumePlugin == nil {
229
+ err = fmt .Errorf ("plugin do not support attachment" )
230
+ }
228
231
return "" , fmt .Errorf (
229
232
"failed to get AttachablePlugin from volumeSpec for volume %q err=%v" ,
230
233
volumeSpec .Name (),
You can’t perform that action at this time.
0 commit comments