From 44de29d04d1ca7e3b047b2a847508dc949c29038 Mon Sep 17 00:00:00 2001 From: "lpsolit%gmail.com" <> Date: Tue, 25 Oct 2005 06:11:55 +0000 Subject: Bug 312157: Remove $::template and $::vars from globals.pl - Patch by Olav Vitters r=LpSolit a=justdave --- Bugzilla/User.pm | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'Bugzilla/User.pm') diff --git a/Bugzilla/User.pm b/Bugzilla/User.pm index 744dbd34a..7f3736c28 100644 --- a/Bugzilla/User.pm +++ b/Bugzilla/User.pm @@ -892,8 +892,6 @@ sub match_field { # prepare default form values - my $vars = $::vars; - # What does a "--do_not_change--" field look like (if any)? my $dontchange = $cgi->param('dontchange'); @@ -1056,6 +1054,9 @@ sub match_field { # Skip confirmation if we were told to, or if we don't need to confirm. return $retval if ($behavior == MATCH_SKIP_CONFIRM || !$need_confirm); + my $template = Bugzilla->template; + my $vars = {}; + $vars->{'script'} = $ENV{'SCRIPT_NAME'}; # for self-referencing URLs $vars->{'fields'} = $fields; # fields being matched $vars->{'matches'} = $matches; # matches that were made @@ -1063,8 +1064,8 @@ sub match_field { print Bugzilla->cgi->header(); - $::template->process("global/confirm-user-match.html.tmpl", $vars) - || ThrowTemplateError($::template->error()); + $template->process("global/confirm-user-match.html.tmpl", $vars) + || ThrowTemplateError($template->error()); exit; -- cgit v1.2.3-24-g4f1b