Skip to content

Instantly share code, notes, and snippets.

@jjn1056
Created October 23, 2009 13:45
Show Gist options
  • Save jjn1056/216889 to your computer and use it in GitHub Desktop.
Save jjn1056/216889 to your computer and use it in GitHub Desktop.
use CatalystX::Declare; {
controller MyApp::Web::Controller::Error {
action start under '/start' as 'error' {
## I'd think this action would get called in a go but no!
}
under start {
final action not_found(@) is private {
$ctx->stash(missing => $ctx->request->uri);
$ctx->response->status(404);
}
final action unauthorized(@) is private {
$ctx->stash(blocked => $ctx->request->uri);
$ctx->response->status(401);
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment