Skip to content

Commit

Permalink
[#117 state:committed] Fixed an issue in MT::Bootstrap where DebugMod…
Browse files Browse the repository at this point in the history
…e was never recognized due to a missing "require MT::ConfigMgr;" in an eval'd block. This led to extremely unsatisfying error messages in app initialization.
  • Loading branch information
jayallen committed Jul 26, 2009
1 parent 6447f0e commit 5b37259
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lib/MT/Bootstrap.pm
Original file line number Diff line number Diff line change
Expand Up @@ -163,6 +163,7 @@ sub import {
my $charset = 'utf-8';
eval {
# line __LINE__ __FILE__
require MT::ConfigMgr;
my $cfg = MT::ConfigMgr->instance; #this is needed
$app ||= MT->instance;
my $c = $app->find_config;
Expand Down Expand Up @@ -193,6 +194,9 @@ sub import {
}
if (!$MT::DebugMode && ($err =~ m/^(.+?)( at .+? line \d+)(.*)$/s)) {
$err = $1;
$err .= '. '
. $app->translate('Enable DebugMode for more details.');

}
print "Content-Type: text/plain; charset=$charset\n\n";
print $app
Expand Down

0 comments on commit 5b37259

Please sign in to comment.