mirror of
https://github.com/vmware-tanzu/velero.git
synced 2026-01-08 14:21:18 +00:00
Merge pull request #5401 from shubham-pampattiwar/add-vsc-nil-check
Add nil check before execution of csi snapshot delete
This commit is contained in:
1
changelogs/unreleased/5401-shubham-pampattiwar
Normal file
1
changelogs/unreleased/5401-shubham-pampattiwar
Normal file
@@ -0,0 +1 @@
|
||||
Add nil check before execution of csi snapshot delete
|
||||
@@ -707,7 +707,9 @@ func (c *backupController) runBackup(backup *pkgbackup.Request) error {
|
||||
}
|
||||
|
||||
// Delete the VolumeSnapshots created in the backup, when CSI feature is enabled.
|
||||
c.deleteVolumeSnapshot(volumeSnapshots, volumeSnapshotContents, *backup, backupLog)
|
||||
if len(volumeSnapshots) > 0 && len(volumeSnapshotContents) > 0 {
|
||||
c.deleteVolumeSnapshot(volumeSnapshots, volumeSnapshotContents, *backup, backupLog)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user