X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=catagits%2FCatalyst-Runtime.git;a=blobdiff_plain;f=lib%2FCatalyst%2FEngine.pm;h=443975ed05704b2fd544a80ddb8f0f1584a94f14;hp=32cac013f1e089db3f5e1fda92bc5a3e0d9e56fc;hb=df960201c8d8c22edddedced4471c14606877145;hpb=81f25ce60d12146ada6baa3ed8db87a0e8a54408 diff --git a/lib/Catalyst/Engine.pm b/lib/Catalyst/Engine.pm index 32cac01..443975e 100644 --- a/lib/Catalyst/Engine.pm +++ b/lib/Catalyst/Engine.pm @@ -112,7 +112,7 @@ sub finalize_error { my ( $self, $c ) = @_; $c->res->content_type('text/html; charset=utf-8'); - my $name = $c->config->{name} || join(' ', split('::', ref $c)); + my $name = ref($c)->config->{name} || join(' ', split('::', ref $c)); my ( $title, $error, $infos ); if ( $c->debug ) { @@ -317,13 +317,14 @@ sets up the L object body using L sub prepare_body { my ( $self, $c ) = @_; + my $appclass = ref($c) || $c; if ( my $length = $self->read_length ) { my $request = $c->request; unless ( $request->_body ) { my $type = $request->header('Content-Type'); $request->_body(HTTP::Body->new( $type, $length )); - $request->_body->tmpdir( $c->config->{uploadtmp} ) - if exists $c->config->{uploadtmp}; + $request->_body->tmpdir( $appclass->config->{uploadtmp} ) + if exists $appclass->config->{uploadtmp}; } while ( my $buffer = $self->read($c) ) {