diff options
author | mkanat%bugzilla.org <> | 2006-07-06 15:12:04 +0200 |
---|---|---|
committer | mkanat%bugzilla.org <> | 2006-07-06 15:12:04 +0200 |
commit | f162521444148d622df3b42a8304b6cce8f2150e (patch) | |
tree | 78cf6a0bfad99a4f053c998b98efe36929475005 /votes.cgi | |
parent | 5e55e7bc89682617a14d5fbc3b6098c12ce1aece (diff) | |
download | bugzilla-f162521444148d622df3b42a8304b6cce8f2150e.tar.gz bugzilla-f162521444148d622df3b42a8304b6cce8f2150e.tar.xz |
Bug 173629: Clean up "my" variable scoping issues for mod_perl
Patch By Max Kanat-Alexander <mkanat@bugzilla.org> r=LpSolit, a=myk
Diffstat (limited to 'votes.cgi')
-rwxr-xr-x | votes.cgi | 8 |
1 files changed, 6 insertions, 2 deletions
@@ -38,8 +38,7 @@ use Bugzilla::Product; use List::Util qw(min); my $cgi = Bugzilla->cgi; -my $template = Bugzilla->template; -my $vars = {}; +local our $vars = {}; # If the action is show_bug, you need a bug_id. # If the action is show_user, you can supply a userid to show the votes for @@ -94,6 +93,8 @@ exit; sub show_bug { my $cgi = Bugzilla->cgi; my $dbh = Bugzilla->dbh; + my $template = Bugzilla->template; + my $bug_id = $cgi->param('bug_id'); ThrowCodeError("missing_bug_id") unless defined $bug_id; @@ -117,6 +118,8 @@ sub show_user { my $cgi = Bugzilla->cgi; my $dbh = Bugzilla->dbh; my $user = Bugzilla->user; + my $template = Bugzilla->template; + my $bug_id = $cgi->param('bug_id'); # If a bug_id is given, and we're editing, we'll add it to the votes list. $bug_id ||= ""; @@ -215,6 +218,7 @@ sub record_votes { my $cgi = Bugzilla->cgi; my $dbh = Bugzilla->dbh; + my $template = Bugzilla->template; # Build a list of bug IDs for which votes have been submitted. Votes # are submitted in form fields in which the field names are the bug |