handles => [
qw/
controllers
+ controller
models
views
component
=cut
-sub controller {
- my ( $c, $name, @args ) = @_;
-
- if( $name ) {
- my @result = $c->_comp_search_prefixes( $name, qw/Controller C/ );
- return map { $c->_filter_component( $_, @args ) } @result if ref $name;
- return $c->_filter_component( $result[ 0 ], @args );
- }
-
- return $c->component( $c->action->class );
-}
-
=head2 $c->model($name)
Gets a L<Catalyst::Model> instance by name.