diff options
Diffstat (limited to 'lib/JWebmail.pm')
-rw-r--r-- | lib/JWebmail.pm | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/lib/JWebmail.pm b/lib/JWebmail.pm index 3abc78d..6963d44 100644 --- a/lib/JWebmail.pm +++ b/lib/JWebmail.pm @@ -44,6 +44,7 @@ sub startup { $self->plugin('ServerSideSessionData'); } $self->plugin('Helper'); + $self->plugin('RenderMail'); my $i18n_route = $self->plugin('I18N2', $self->config('i18n')); $self->secrets( [$self->config('secret')] ) if $self->config('secret'); @@ -85,17 +86,18 @@ sub route { my $r = shift || $self->routes; - $r->get('/' => 'login')->to('Webmail#noaction'); + $r->get( '/' => 'login')->to('Webmail#noaction'); $r->post('/' => 'login')->to('Webmail#login'); - $r->get('/about')->to('Webmail#about'); - $r->get('/logout')->to('Webmail#logout'); + $r->get('/about' )->to('Webmail#about'); + $r->get('/logout' )->to('Webmail#logout'); my $a = $r->under('/')->to('Webmail#auth'); - $a->get('/home/*folder')->to('Webmail#displayheaders', folder => '')->name('displayheaders'); + $a->get('/home/*folder' )->to('Webmail#displayheaders', folder => '')->name('displayheaders'); $a->get('/read/#id' => 'read')->to('Webmail#readmail'); - $a->get('/write')->to('Webmail#writemail'); - $a->post('/write' => 'send')->to('Webmail#sendmail'); - $a->post('/move')->to('Webmail#move'); + $a->get('/raw/#id' => 'raw' )->to('Webmail#raw'); + $a->get('/write' )->to('Webmail#writemail'); + $a->post('/write' => 'send' )->to('Webmail#sendmail'); + $a->post('/move' )->to('Webmail#move'); } |