Reworked error handling to propogate errors downward, especially when webgui.debug is set
This commit is contained in:
parent
b815228a1b
commit
e945a94c63
12 changed files with 132 additions and 110 deletions
|
|
@ -47,13 +47,8 @@ sub call {
|
|||
$app = Plack::Middleware::SimpleLogger->wrap( $app );
|
||||
}
|
||||
|
||||
my $session = try {
|
||||
$env->{'webgui.session'} = WebGUI::Session->open( $config, $env );
|
||||
} catch {
|
||||
# We don't have a logger object, so for now just warn() the error
|
||||
warn "Unable to instantiate WebGUI::Session - $_";
|
||||
return; # make sure $session assignment is undef
|
||||
};
|
||||
my $session = $env->{'webgui.session'} = WebGUI::Session->open( $config, $env ) or
|
||||
die "Unable to instantiate WebGUI::Session - $_";
|
||||
|
||||
if ( !$session ) {
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue