# see UNDER above get 'get_first' => sub { my $c = shift; return $c->render(text => $text_a); }; # see UNDER above get 'get_second' => sub { my $c = shift; return $c->render(text => $text_b); }; #### # Admin section group { # Local logic shared only by routes in this group under '/admin' => sub { my $c = shift; return 1 if $c->req->headers->header('X-Awesome'); $c->render(text => "You're not awesome enough."); return undef; }; # GET /admin/dashboard get '/dashboard' => {text => 'Nothing to see here yet.'}; };