X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=catagits%2FCatalyst-Runtime.git;a=blobdiff_plain;f=lib%2FCatalyst%2FAction.pm;h=3497e21ec59bb1678efa1816cf4965a86a7f5c9c;hp=ea3e3e49e820122e5fa612ef6e5657cb54de067e;hb=1d00b2ffb8806bd0a8190ee8580a85895e48f8e4;hpb=1c20c63931df63b579c27cf822bc933211d33df9 diff --git a/lib/Catalyst/Action.pm b/lib/Catalyst/Action.pm index ea3e3e4..3497e21 100644 --- a/lib/Catalyst/Action.pm +++ b/lib/Catalyst/Action.pm @@ -52,9 +52,7 @@ has number_of_args => ( if( ! exists $self->attributes->{Args} ) { # When 'Args' does not exist, that means we want 'any number of args'. return undef; - } elsif( - !defined($self->attributes->{Args}[0]) || - $self->attributes->{Args}[0] eq '' ) { + } elsif(!defined($self->attributes->{Args}[0])) { # When its 'Args' that internal cue for 'unlimited' return undef; } elsif( @@ -140,7 +138,6 @@ has args_constraints => ( return [] unless scalar(@arg_protos); return [] unless defined($arg_protos[0]); - return [] if ($arg_protos[0] eq '' && scalar(@arg_protos) == 1); # If there is only one arg and it looks like a number # we assume its 'classic' and the number is the number of