diff --git a/lib/Engage/WUI/Base/Application.pm b/lib/Engage/WUI/Application.pm similarity index 71% rename from lib/Engage/WUI/Base/Application.pm rename to lib/Engage/WUI/Application.pm index 7b91dca..5ed3702 100644 --- a/lib/Engage/WUI/Base/Application.pm +++ b/lib/Engage/WUI/Application.pm @@ -1,4 +1,4 @@ -package Engage::WUI::Base::Application; +package Engage::WUI::Application; use Moose; use Catalyst::Runtime 5.80; @@ -14,16 +14,15 @@ BEGIN { $StartedOn = Time::HiRes::time; } -after setup_finalize => sub { +after 'setup_finalize' => sub { my $c = shift; $c->log->info(sprintf 'Setup took %0.6fs', Time::HiRes::time - $StartedOn ); $c->log->_flush if $c->log->can('_flush'); }; -override finalize => sub { +after 'finalize_error' => sub { my $c = shift; - $c->forward('/error/handle_exception') if @{ $c->error }; - $c->next::method( @_ ); + $c->forward('/error/handle_exception'); }; no Moose; diff --git a/lib/Engage/WUI/Base/Controller/Error.pm b/lib/Engage/WUI/Controller/Error.pm similarity index 93% rename from lib/Engage/WUI/Base/Controller/Error.pm rename to lib/Engage/WUI/Controller/Error.pm index d1b0606..ae257f5 100644 --- a/lib/Engage/WUI/Base/Controller/Error.pm +++ b/lib/Engage/WUI/Controller/Error.pm @@ -1,4 +1,4 @@ -package Engage::WUI::Base::Controller::Error; +package Engage::WUI::Controller::Error; use Moose; use HTTP::Status; diff --git a/lib/Engage/WUI/Base/Controller/Root.pm b/lib/Engage/WUI/Controller/Root.pm similarity index 97% rename from lib/Engage/WUI/Base/Controller/Root.pm rename to lib/Engage/WUI/Controller/Root.pm index ad5945d..c9ac73d 100644 --- a/lib/Engage/WUI/Base/Controller/Root.pm +++ b/lib/Engage/WUI/Controller/Root.pm @@ -1,4 +1,4 @@ -package Engage::WUI::Base::Controller::Root; +package Engage::WUI::Controller::Root; =head1 NAME