X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=lib%2FMooseX%2FTypes%2FWrapper.pm;fp=lib%2FMooseX%2FTypes%2FWrapper.pm;h=60a8ebd8f884a9e4dca6e271363d66b3580c5d03;hb=e9dc30af81ed775a6ac0a0f0c1daad021e5569f6;hp=388a53595ee7a25da5b6e4fca09c92e356b52e2b;hpb=a2487cfb17f24711667462ae01dc8cf8a47ac87e;p=gitmo%2FMooseX-Types.git diff --git a/lib/MooseX/Types/Wrapper.pm b/lib/MooseX/Types/Wrapper.pm index 388a535..60a8ebd 100644 --- a/lib/MooseX/Types/Wrapper.pm +++ b/lib/MooseX/Types/Wrapper.pm @@ -30,11 +30,11 @@ sub import { croak qq($class expects an array reference as import spec) unless ref $libraries{ $l } eq 'ARRAY'; - my $library_class + my $library_class = ($l eq 'Moose' ? 'MooseX::Types::Moose' : $l ); Class::MOP::load_class($library_class); - $library_class->import({ + $library_class->import({ -into => scalar(caller), -wrapper => $class, }, @{ $libraries{ $l } });