Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
use strict;
use warnings;
use strict;
use warnings;
use Digest::SHA;
use PVE::Exception qw(raise_param_exc);
use Digest::SHA;
use PVE::Exception qw(raise_param_exc);
sub lookup {
my ($class, $type) = @_;
sub lookup {
my ($class, $type) = @_;
+ croak "cannot lookup undefined type!" if !defined($type);
+
my $pdata = $class->private();
my $plugin = $pdata->{plugins}->{$type};
my $pdata = $class->private();
my $plugin = $pdata->{plugins}->{$type};