5
0
mirror of git://git.proxmox.com/git/pve-guest-common.git synced 2025-01-10 01:17:51 +03:00

config: snapshot delete check: use volume_snapshot_info

Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
This commit is contained in:
Fabian Ebner 2021-10-19 09:54:56 +02:00 committed by Fabian Grünbichler
parent b20bf9bf7d
commit 2511f525f5

View File

@ -846,14 +846,14 @@ my $snapshot_delete_assert_not_needed_by_replication = sub {
return if !$volumes->{$volid};
my $snapshots = PVE::Storage::volume_snapshot_list($storecfg, $volid);
my $snapshots = PVE::Storage::volume_snapshot_info($storecfg, $volid);
for my $job ($replication_jobs->@*) {
my $jobid = $job->{id};
my @jobs_snapshots = grep {
PVE::Replication::is_replication_snapshot($_, $jobid)
} $snapshots->@*;
} keys $snapshots->%*;
next if scalar(@jobs_snapshots) > 0;