[Rt-commit] rt branch, new-style-templates, updated. rt-3.8.8-221-ga6f22ed

Shawn Moore sartak at bestpractical.com
Mon Jul 26 20:55:16 EDT 2010


The branch, new-style-templates has been updated
       via  a6f22ed89acc2b54fb6c75771129e1e2c1e23821 (commit)
      from  2c3696d23a30d2e00d15a6b5a0ff222666141031 (commit)

Summary of changes:
 lib/RT/Template_Overlay.pm |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)

- Log -----------------------------------------------------------------
commit a6f22ed89acc2b54fb6c75771129e1e2c1e23821
Author: Shawn M Moore <sartak at bestpractical.com>
Date:   Mon Jul 26 20:56:40 2010 -0400

    no strict 'vars' for compile-time checking of templates
    
        Otherwise all the builtin templates that reference a variable throw
        a warning about bad variables

diff --git a/lib/RT/Template_Overlay.pm b/lib/RT/Template_Overlay.pm
index 28294cc..4ffa706 100755
--- a/lib/RT/Template_Overlay.pm
+++ b/lib/RT/Template_Overlay.pm
@@ -662,7 +662,10 @@ sub CompileCheck {
         my ($fi_type, $fi_text, $fi_lineno) = @$fi_item;
         next unless $fi_type eq 'PROG';
 
-        eval "sub { $fi_text }";
+        do {
+            no strict 'vars';
+            eval "sub { $fi_text }";
+        };
         next if !$@;
 
         my $error = $@;

-----------------------------------------------------------------------


More information about the Rt-commit mailing list