diff options
author | Christian Ruppert <idl0r@gentoo.org> | 2015-07-11 15:27:33 +0200 |
---|---|---|
committer | Christian Ruppert <idl0r@gentoo.org> | 2015-07-11 15:27:33 +0200 |
commit | 4b2ce2725e9a4525e273fb1b08243aad74770a3d (patch) | |
tree | c90fb0fef5c9ac923817f908f1c3586efa47ec59 /show_bug.cgi | |
parent | Bumped version to 4.4.9 (diff) | |
download | bugzilla-4b2ce2725e9a4525e273fb1b08243aad74770a3d.tar.gz bugzilla-4b2ce2725e9a4525e273fb1b08243aad74770a3d.tar.bz2 bugzilla-4b2ce2725e9a4525e273fb1b08243aad74770a3d.zip |
Vanilla 4.4.9 to 5.0 without history due to massive merge conflicts
Diffstat (limited to 'show_bug.cgi')
-rwxr-xr-x | show_bug.cgi | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/show_bug.cgi b/show_bug.cgi index 846cf64d5..f69cae740 100755 --- a/show_bug.cgi +++ b/show_bug.cgi @@ -1,4 +1,4 @@ -#!/usr/bin/perl -wT +#!/usr/bin/perl -T # This Source Code Form is subject to the terms of the Mozilla Public # License, v. 2.0. If a copy of the MPL was not distributed with this # file, You can obtain one at http://mozilla.org/MPL/2.0/. @@ -6,7 +6,9 @@ # This Source Code Form is "Incompatible With Secondary Licenses", as # defined by the Mozilla Public License, v. 2.0. +use 5.10.1; use strict; +use warnings; use lib qw(. lib); @@ -39,14 +41,14 @@ if (!$cgi->param('id') && $single) { my (@bugs, @illegal_bugs); my %marks; -# If the user isn't logged in, we use data from the shadow DB. If he plans -# to edit the bug(s), he will have to log in first, meaning that the data +# If the user isn't logged in, we use data from the shadow DB. If they plan +# to edit the bug(s), they will have to log in first, meaning that the data # will be reloaded anyway, from the main DB. Bugzilla->switch_to_shadow_db unless $user->id; if ($single) { my $id = $cgi->param('id'); - push @bugs, Bugzilla::Bug->check($id); + push @bugs, Bugzilla::Bug->check({ id => $id, cache => 1 }); if (defined $cgi->param('mark')) { foreach my $range (split ',', $cgi->param('mark')) { if ($range =~ /^(\d+)-(\d+)$/) { @@ -66,7 +68,7 @@ if ($single) { foreach my $bug_id (@ids) { next unless $bug_id; - my $bug = new Bugzilla::Bug($bug_id); + my $bug = new Bugzilla::Bug({ id => $bug_id, cache => 1 }); if (!$bug->{error}) { push(@check_bugs, $bug); } @@ -110,7 +112,7 @@ if ($cgi->param("field")) { } unless ($user->is_timetracker) { - @fieldlist = grep($_ !~ /(^deadline|_time)$/, @fieldlist); + @fieldlist = grep($_ !~ /_time$/, @fieldlist); } foreach (@fieldlist) { |