X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=lib%2FCatalyst%2FBase.pm;h=42f28bef609770b218aad7a173f3b8966ca0a081;hb=1cf67b316803ae09bffed9eee0aaee0e011ce2c0;hp=1b672f0941861f385536bb39f9b2d1c42b749b2c;hpb=245ae014f237e59c7b9f0596c6dddf19593512fa;p=catagits%2FCatalyst-Runtime.git diff --git a/lib/Catalyst/Base.pm b/lib/Catalyst/Base.pm index 1b672f0..42f28be 100644 --- a/lib/Catalyst/Base.pm +++ b/lib/Catalyst/Base.pm @@ -43,7 +43,10 @@ sub _AUTO : Private { sub _ACTION : Private { my ( $self, $c ) = @_; - if ( ref $c->action && $c->action->isa('Catalyst::Action') ) { + if ( ref $c->action + && $c->action->can('execute') + && $c->req->action ) + { $c->action->execute($c); } return !@{ $c->error }; @@ -71,20 +74,19 @@ Catalyst Base Class =head1 METHODS -=over 4 - -=item $self->action_namespace($c) +=head2 $self->action_namespace($c) =cut sub action_namespace { my ( $self, $c ) = @_; - return Catalyst::Utils::class2prefix( ref $self, + return $self->config->{namespace} if exists $self->config->{namespace}; + return Catalyst::Utils::class2prefix( ref($self) || $self, $c->config->{case_sensitive} ) || ''; } -=item $self->register_actions($c) +=head2 $self->register_actions($c) =cut @@ -152,8 +154,6 @@ sub _parse_attrs { return \%attributes; } -=back - =head1 SEE ALSO L, L.