From: Dan Scott <dscott@laurentian.ca>
Date: Fri, 20 Jul 2012 17:41:50 +0000 (-0400)
Subject: TPAC: Decode translated strings into UTF8
X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=939f1e7d3e12051fa6d49a537de2ab9c00701d6d;p=evergreen%2Fmasslnc.git

TPAC: Decode translated strings into UTF8

Without the _decode pragma, Locale::Maketext::Lexixcon did not
understand that it was being handed Unicode and generated some funky
output in the TPAC templates.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
---

diff --git a/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGWeb.pm b/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGWeb.pm
index 34bb4861f6..71a520ce28 100644
--- a/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGWeb.pm
+++ b/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGWeb.pm
@@ -284,6 +284,9 @@ sub load_locale_handlers {
             package OpenILS::WWW::EGWeb::I18N::$tag;
             use base 'OpenILS::WWW::EGWeb::I18N$parent_tag';
             if(\$messages) {
+                use Locale::Maketext::Lexicon {
+                    _decode => 1
+                };
                 use Locale::Maketext::Lexicon::Gettext;
                 if(open F, '$messages') {
                     our %Lexicon = (%Lexicon, %{ Locale::Maketext::Lexicon::Gettext->parse(<F>) });