X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=catagits%2FCatalyst-Runtime.git;a=blobdiff_plain;f=lib%2FCatalyst%2FEngine.pm;h=d6673a294d1362961ca56f6da45db86662a2317c;hp=d061984f51456fe8fb832d343edfac3b74832303;hb=c19e2f4a25812c000f047d6128d566c55972f9f2;hpb=386777dc6439f150392cbca5da094803296d3640 diff --git a/lib/Catalyst/Engine.pm b/lib/Catalyst/Engine.pm index d061984..d6673a2 100644 --- a/lib/Catalyst/Engine.pm +++ b/lib/Catalyst/Engine.pm @@ -698,8 +698,8 @@ Returns a hashref containing all your data. sub stash { my $self = shift; - if ( $_[0] ) { - my $stash = $_[1] ? {@_} : $_[0]; + if ( @_ ) { + my $stash = @_ > 1 ? {@_} : $_[0]; while ( my ( $key, $val ) = each %$stash ) { $self->{stash}->{$key} = $val; }