[Catalyst-commits] r12911 - Catalyst-View-TT/branches/render_die/lib/Catalyst/View

t0m at dev.catalyst.perl.org t0m at dev.catalyst.perl.org
Tue Feb 16 22:37:01 GMT 2010


Author: t0m
Date: 2010-02-16 22:37:01 +0000 (Tue, 16 Feb 2010)
New Revision: 12911

Modified:
   Catalyst-View-TT/branches/render_die/lib/Catalyst/View/TT.pm
Log:
Localise execeptions

Modified: Catalyst-View-TT/branches/render_die/lib/Catalyst/View/TT.pm
===================================================================
--- Catalyst-View-TT/branches/render_die/lib/Catalyst/View/TT.pm	2010-02-16 22:23:03 UTC (rev 12910)
+++ Catalyst-View-TT/branches/render_die/lib/Catalyst/View/TT.pm	2010-02-16 22:37:01 UTC (rev 12911)
@@ -168,6 +168,7 @@
                                    @{ $p->{copy_config} };
                     }
                 }
+                local $@;
                 eval "require $prov";
                 if(!$@) {
                     push @providers, "$prov"->new($p->{args});
@@ -207,6 +208,7 @@
         return 0;
     }
 
+    local $@;
     my $output = eval { $self->render($c, $template) };
     if (my $err = $@) {
         my $error = qq/Couldn't render template "$template"/;




More information about the Catalyst-commits mailing list