X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=lib%2FMoose%2FMeta%2FMethod%2FDelegation.pm;h=88ea1fa14e0982fc410121902ba8b96d4d9490dd;hb=2cc6f9825ee943b379068b9e9d4938bbc84e0308;hp=04cab205ae690f9f117a1d62a4147101c9513048;hpb=6148c16743ccbfbe259f2b93f239ac5775a218e0;p=gitmo%2FMoose.git diff --git a/lib/Moose/Meta/Method/Delegation.pm b/lib/Moose/Meta/Method/Delegation.pm index 04cab20..88ea1fa 100644 --- a/lib/Moose/Meta/Method/Delegation.pm +++ b/lib/Moose/Meta/Method/Delegation.pm @@ -7,7 +7,7 @@ use warnings; use Carp 'confess'; use Scalar::Util 'blessed', 'weaken'; -our $VERSION = '0.85'; +our $VERSION = '0.86'; $VERSION = eval $VERSION; our $AUTHORITY = 'cpan:STEVAN'; @@ -81,9 +81,9 @@ sub _initialize_body { my $proxy = $instance->$accessor(); my $error - = !defined $proxy ? ' is not defined' - : !blessed $proxy ? qq{ is not an object (got '$proxy')} - : undef; + = !defined $proxy ? ' is not defined' + : ref($proxy) && !blessed($proxy) ? qq{ is not an object (got '$proxy')} + : undef; if ($error) { $self->throw_error(