package CMTD; use strict; use warnings; use Mojo::Base 'Mojolicious'; sub startup { my $self = shift; $self->plugin('CMTD::Helpers'); $self->plugin(Config => {file => 'cmtd.conf'}); my $r = $self->routes; $r->get('/') -> to('main#index'); $r->get('/captcha') -> to('main#captcha'); $r->get('/comments/list') -> to('main#c_list'); $r->get('/comments/add') -> to('main#c_add'); } 1;