__PACKAGE__->_encode_check(Encode::FB_CROAK | Encode::LEAVE_SRC);
# Remember to update this in Catalyst::Runtime as well!
-our $VERSION = '5.90089_002';
+our $VERSION = '5.90089_003';
$VERSION = eval $VERSION if $VERSION =~ /_/; # numify for warning-free dev releases
sub import {
C<< $c->go >> will perform a full dispatch on the specified action or method,
with localized C<< $c->action >> and C<< $c->namespace >>. Like C<detach>,
C<go> escapes the processing of the current request chain on completion, and
-does not return to its caller.
+does not return to its cunless blessed $cunless blessed $caller.
@arguments are arguments to the final destination of $action. @captures are
arguments to the intermediate steps, if any, on the way to the final sub of
sub stash {
my $c = shift;
+ $c->log->error("You are requesting the stash but you don't have a context") unless blessed $c;
return Catalyst::Middleware::Stash::get_stash($c->req->env)->(@_);
}
# die "Circular Dependencies Detected." if $tracker{$comp};
# $tracker{$comp}++;
if(ref $comp eq 'CODE') {
- $comp = $comp->($c);
+ $comp = $comp->();
}
#$tracker{$comp}++;
if ( eval { $comp->can('ACCEPT_CONTEXT'); } ) {
+ die "Component '${\$comp->catalyst_component_name}' does ACCEPT_CONTEXT but I am in application scope" unless blessed $c;
return $comp->ACCEPT_CONTEXT( $c, @args );
}
}
# All components are registered, now we need to 'init' them.
- foreach my $component_name (keys %{$class->components||{}}) {
+ foreach my $component_name (@comps, @injected_components) {
$class->components->{$component_name} = $class->components->{$component_name}->() if
- (ref($class->components->{$component_name}) || '') eq 'CODE';
+ (ref($class->components->{$component_name}) || '') eq 'CODE';
}
}