DispatchType::Chained fix failing test of Args(0) vs Args(0) on surface
Gareth Kirwan [Fri, 7 Aug 2009 17:17:15 +0000 (17:17 +0000)]
lib/Catalyst/DispatchType/Chained.pm

index 3495749..ba488df 100644 (file)
@@ -235,7 +235,8 @@ sub recurse_match {
                 }
 
                 # Default args is blank, not 0, since Args()
-                my $args_attr = $action->attributes->{Args}->[0] || '';
+                my $args_attr = $action->attributes->{Args}->[0];
+                $args_attr = '' unless defined $args_attr;
 
                 #    No best action currently
                 # OR This one matches with fewer parts left than the current best action,