Skip to content

Commit

Permalink
work around Structured TC bug?
Browse files Browse the repository at this point in the history
  • Loading branch information
jrockway committed Apr 6, 2009
1 parent 7dec82b commit 98625d8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/MooseX/Method/Signatures/Meta/Method.pm
Expand Up @@ -123,7 +123,7 @@ sub wrap {
return preserve_context { $self->actual_body->(@args) }
after => sub {
if (defined (my $msg = $self->_return_type_constraint->validate(\@_))) {
confess $msg;
confess $msg unless $msg eq '1';
}
};
};
Expand Down Expand Up @@ -337,7 +337,7 @@ sub validate {
if $coerced == $args;

if (defined (my $msg = $self->type_constraint->validate($coerced))) {
confess $msg;
confess $msg unless $msg eq '1';
}

return @{ $coerced->[0] }, map { $coerced->[1]->{$_} } @named;
Expand Down

0 comments on commit 98625d8

Please sign in to comment.