]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
Bug 360626 - "ThrowTemplateError() used in Util.pm" [p=reed r=LpSolit a=LpSolit]
authorreed%reedloden.com <>
Wed, 18 Nov 2009 18:25:45 +0000 (18:25 +0000)
committerreed%reedloden.com <>
Wed, 18 Nov 2009 18:25:45 +0000 (18:25 +0000)
Bugzilla/Util.pm

index b3d5b0eaadba3d3b55d59ec15caa773f698f3ddc..2ffd3efeb23506153601373d34e4bdfdb9775334 100644 (file)
@@ -600,8 +600,10 @@ sub get_text {
     $vars ||= {};
     $vars->{'message'} = $name;
     my $message;
-    $template->process('global/message.txt.tmpl', $vars, \$message)
-        || ThrowTemplateError($template->error());
+    if (!$template->process('global/message.txt.tmpl', $vars, \$message)) {
+        require Bugzilla::Error;
+        Bugzilla::Error::ThrowTemplateError($template->error());
+    }
     # Remove the indenting that exists in messages.html.tmpl.
     $message =~ s/^    //gm;
     return $message;