X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=catagits%2FCatalyst-Runtime.git;a=blobdiff_plain;f=lib%2FCatalyst.pm;fp=lib%2FCatalyst.pm;h=92ec1807fa2384ca33a5db9f158ec9f21e2c9c45;hp=c6ccc596be405b1c0ba794e8f74d09e564ec7b8b;hb=0d42b769cb502cae1587cbe8e606ea15921508d2;hpb=53c7cc10e26c965f7502936609c5d1e6a35dc819 diff --git a/lib/Catalyst.pm b/lib/Catalyst.pm index c6ccc59..92ec180 100644 --- a/lib/Catalyst.pm +++ b/lib/Catalyst.pm @@ -1640,8 +1640,9 @@ sub uri_for { if($num_captures) { unless($expanded_action->match_captures_constraints($c, $captures)) { - carp "captures [@{$captures}] do not match the type constraints in actionchain ending with '$expanded_action'"; - return; + $c->log->debug("captures [@{$captures}] do not match the type constraints in actionchain ending with '$expanded_action'") + if $c->debug; + return undef; } } @@ -1656,8 +1657,9 @@ sub uri_for { # At this point @encoded_args is the remaining Args (all captures removed). if($expanded_action->has_args_constraints) { unless($expanded_action->match_args($c,\@args)) { - carp "args [@args] do not match the type constraints in action '$expanded_action'"; - return; + $c->log->debug("args [@args] do not match the type constraints in action '$expanded_action'") + if $c->debug; + return undef; } } }