]> git.imager.perl.org - bse.git/commitdiff
allow the state variable to be replaced properly for imageclean
authorTony Cook <tony@develop-help.com>
Fri, 29 May 2015 01:03:10 +0000 (11:03 +1000)
committerTony Cook <tony@develop-help.com>
Fri, 29 May 2015 01:03:10 +0000 (11:03 +1000)
site/cgi-bin/modules/BSE/Request/Base.pm
site/cgi-bin/modules/BSE/Template.pm
site/cgi-bin/modules/BSE/UI/AdminImageClean.pm

index 1fafbbf30f92d34b9cc721999ee0e74fafb6f23a..7fb141327d68fda208a61334bacbc39ec912bd2d 100644 (file)
@@ -5,7 +5,7 @@ use BSE::Cfg;
 use BSE::Util::HTML;
 use Carp qw(cluck confess);
 
-our $VERSION = "1.032";
+our $VERSION = "1.033";
 
 =head1 NAME
 
@@ -1524,7 +1524,7 @@ Return a page response generated from $template and the tags in $acts.
 =cut
 
 sub response {
-  my ($req, $template, $acts) = @_;
+  my ($req, $template, $acts, %opts) = @_;
 
   require BSE::Template;
   my @sets;
@@ -1537,7 +1537,7 @@ sub response {
 
   return BSE::Template->get_response($template, $req->cfg, $acts, 
                                     $template, \@sets, $req->{vars},
-                                    dynamic => 1);
+                                    dynamic => 1, %opts);
 }
 
 =item dyn_user_tags()
index 2fc78a8950259a96aa2e1c2038d195d382585077..b7e67a95c46f8679e8d665e6294ec1b17c853659 100644 (file)
@@ -4,7 +4,7 @@ use Squirrel::Template;
 use Carp qw(confess cluck);
 use Config ();
 
-our $VERSION = "1.014";
+our $VERSION = "1.015";
 
 my %formats =
   (
@@ -62,8 +62,10 @@ sub templater {
        [ "<:", ":>" ],
        [ "[:", ":]" ],
       ];
-    $topts{error_not_defined} =
-      $cfg->entry("basic", "error_not_defined", 1);
+    unless ($opts{twopass}) {
+      $topts{error_not_defined} =
+       $cfg->entry("basic", "error_not_defined", 1);
+    }
   }
 
   return Squirrel::Template->new(%topts);
index b72cd46288eb608f362821c9c6e2351e5832e08c..c6917bf0260bb2fbe54d84069e8e8b16e690a457 100644 (file)
@@ -3,7 +3,7 @@ use strict;
 use base qw(BSE::UI::AdminDispatch);
 use BSE::ImageClean;
 
-our $VERSION = "1.001";
+our $VERSION = "1.002";
 
 =head1 NAME
 
@@ -91,7 +91,7 @@ sub _split_page {
   my ($self, $req, $template) = @_;
 
   my %acts = $req->admin_tags;
-  my $temp_result = $req->response($template, \%acts);
+  my $temp_result = $req->response($template, \%acts, twopass => 1);
   my ($prefix, $per_message, $suffix) =
     split /<:\s*iterator\s+(?:begin|end)\s+messages\s*:>/, $temp_result->{content};