X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=lib%2FCatalyst%2FEngine.pm;h=920fe0e6e84cde964671d08ad53b215ada9a8146;hb=1f9cb7c179c8e4077d99badf31f3a356efdc809c;hp=544116d89f327d83365dc5e90be2080a80e94672;hpb=7299a7b440fa6c3084ae678e8d32f52066ee84d6;p=catagits%2FCatalyst-Runtime.git diff --git a/lib/Catalyst/Engine.pm b/lib/Catalyst/Engine.pm index 544116d..920fe0e 100644 --- a/lib/Catalyst/Engine.pm +++ b/lib/Catalyst/Engine.pm @@ -47,7 +47,7 @@ sub finalize_body { if ( ref $c->response->body && $c->response->body->can('read') ) { while ( !$c->response->body->eof() ) { $c->response->body->read( my $buffer, $CHUNKSIZE ); - $self->write( $c, $buffer ); + last unless $self->write( $c, $buffer ); } $c->response->body->close(); } @@ -99,10 +99,11 @@ sub finalize_error { # For pretty dumps local $Data::Dumper::Terse = 1; $error = join '', - map { '' . encode_entities($_) . '' } + map { '

' . encode_entities($_) . '

' } @{ $c->error }; $error ||= 'No output'; $title = $name = "$name on Catalyst $Catalyst::VERSION"; + $name = "

$name

"; # Don't show context in the dump delete $c->req->{_context}; @@ -124,12 +125,7 @@ sub finalize_error { my $name = $dump->[0]; my $value = encode_entities( Dumper $dump->[1] ); push @infos, sprintf <<"EOF", $name, $value; -
- - %s - -
-
+

%s

%s
@@ -189,6 +185,7 @@ EOF color: #ddd; } div.box { + position: relative; background-color: #ccc; border: 1px solid #aaa; padding: 4px; @@ -224,6 +221,20 @@ EOF overflow: auto; white-space: pre; } + div.name h1, div.error p { + margin: 0; + } + h2 { + margin-top: 0; + margin-bottom: 10px; + font-size: medium; + font-weight: bold; + text-decoration: underline; + } + h1 { + font-size: medium; + font-weight: normal; + }