1 package Debbugs::Mojo::Controller::Bug;
3 use Mojo::Base 'Mojolicious::Controller';
9 my $id = $c->stash('bug');
10 my $bug = Debbugs::Bug->new(bug => $id,
13 return $c->reply->not_found if not $bug->exists;
14 $c->respond_to(json => {json => $bug->structure},
15 any => sub {$c->render(template => 'cgi/bugreport',