Cat5 stuff
[catagits/Catalyst-View-TT.git] / lib / Catalyst / View / TT.pm
index 317b388..1daa3ad 100644 (file)
@@ -6,7 +6,7 @@ use Template;
 use Template::Timer;
 use NEXT;
 
-our $VERSION = '0.08';
+our $VERSION = '0.10';
 
 __PACKAGE__->mk_accessors('template');
 
@@ -105,7 +105,8 @@ stored in C<< $c->response->output >>.
 
 sub process {
     my ( $self, $c ) = @_;
-    $c->res->headers->content_type('text/html;charset=utf8');
+    $c->res->headers->content_type('text/html; charset=utf-8') 
+    unless $c->res->headers->content_type();
     my $output;
     my $name = $c->stash->{template} || $c->req->match;
     unless ($name) {
@@ -129,7 +130,7 @@ sub process {
         my $error = $self->template->error;
         $error = qq/Couldn't render template "$error"/;
         $c->log->error($error);
-        $c->errors($error);
+        $c->error($error);
     }
     $c->res->output($output);
     return 1;