Switched to using log_warn of PVE::RESTEnvironment

Signed-off-by: Daniel Tschlatscher <d.tschlatscher@proxmox.com>
Reviewed-by: Fabian Ebner <f.ebner@proxmox.com>
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
This commit is contained in:
Daniel Tschlatscher
2022-06-14 11:00:12 +02:00
committed by Wolfgang Bumiller
parent e573445e93
commit 3048641bb4

View File

@ -23,6 +23,7 @@ use PVE::JSONSchema;
use PVE::INotify;
use PVE::RPCEnvironment;
use PVE::SSHInfo;
use PVE::RESTEnvironment qw(log_warn);
use PVE::Storage::Plugin;
use PVE::Storage::DirPlugin;
@ -1602,7 +1603,7 @@ sub archive_auxiliaries_remove {
my $path = "$dirname/$filename";
if (-e $path) {
unlink $path or $! == ENOENT or warn "Removing $type file failed: $!\n";
unlink $path or $! == ENOENT or log_warn("Removing $type file failed: $!");
}
}
}