Get rid of the cargo culted code about sending a text reply if the browser didn't specify
that it understands HTML. This interacts badly with Plack::Test and doesn't have much of a point in real life anyway, and I accidentally sent the test up that dends on this being gone without sending this too. Argh. If I could send up a coherent commit just once...
This commit is contained in:
parent
6b0cd93e61
commit
13a2c359e7
1 changed files with 1 additions and 6 deletions
|
|
@ -47,12 +47,7 @@ sub call {
|
|||
my $text = trace_as_string($trace);
|
||||
$env->{'psgi.errors'}->print($text) unless $self->no_print_errors;
|
||||
my $html = eval { trace_as_html($trace, $env->{'webgui.session'}) };
|
||||
if ( $html and ($env->{HTTP_ACCEPT} || '*/*') =~ /html/) {
|
||||
$res = [500, ['Content-Type' => 'text/html; charset=utf-8'], [ utf8_safe($html), @previous_html ] ];
|
||||
} else {
|
||||
$res = [500, ['Content-Type' => 'text/plain; charset=utf-8'], [ utf8_safe($text) ]];
|
||||
}
|
||||
|
||||
$res = [500, ['Content-Type' => 'text/html; charset=utf-8'], [ utf8_safe($html), @previous_html ] ];
|
||||
}
|
||||
|
||||
return $res;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue