sub context_closure : Local {
my ($self, $ctx) = @_;
$ctx->stash(closure => $self->make_context_closure(sub {
+ my ($ctx) = @_;
$ctx->response->body('from context closure');
}, $ctx));
$ctx->response->body('stashed context closure');
}
+sub non_closure : Local {
+ my ($self, $ctx) = @_;
+ $ctx->stash(no_closure => "not a closure");
+}
+
__PACKAGE__->meta->make_immutable;
1;