From 5873e902d6ea484406d2b522b2b7593cd7cf0c36 Mon Sep 17 00:00:00 2001 From: Bill Erickson Date: Mon, 1 Aug 2011 18:35:39 -0400 Subject: [PATCH] maketext filter must be registered as a dynamic filter to properly handle arguments Signed-off-by: Bill Erickson --- Open-ILS/src/perlmods/lib/OpenILS/WWW/EGWeb.pm | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGWeb.pm b/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGWeb.pm index d684ad04fd..33a5dbb233 100644 --- a/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGWeb.pm +++ b/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGWeb.pm @@ -57,7 +57,15 @@ sub handler { EGI18N => 'OpenILS::WWW::EGWeb::I18NFilter', CGI_utf8 => 'OpenILS::WWW::EGWeb::CGI_utf8' }, - FILTERS => {l => $text_handler} + FILTERS => { + # Register a dynamic filter factory for our locale::maketext generator + l => [ + sub { + my($ctx, @args) = @_; + return sub { $text_handler->(shift(), @args); } + }, 1 + ] + } }); unless($tt->process($template, {ctx => $ctx, ENV => \%ENV, l => $text_handler})) { -- 2.11.0