Bug 611129: Quicksearch fails in 3.6.3 if List::MoreUtils is not installed

r/a=mkanat


git-svn-id: svn://10.0.0.236/branches/BUGZILLA-3_6-BRANCH@261547 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
mkanat%bugzilla.org
2010-11-10 23:46:49 +00:00
parent 2324bbecc4
commit 4502635fa9
2 changed files with 3 additions and 4 deletions

View File

@@ -1 +1 @@
7205
7206

View File

@@ -31,7 +31,6 @@ use Bugzilla::Field;
use Bugzilla::Util;
use List::Util qw(min max);
use List::MoreUtils qw(firstidx);
use base qw(Exporter);
@Bugzilla::Search::Quicksearch::EXPORT = qw(quicksearch);
@@ -447,9 +446,9 @@ sub _special_field_syntax {
my $legal_priorities = get_legal_field_values('priority');
# If Pn exists explicitly, use it.
my $start = firstidx { $_ eq "P$p_start" } @$legal_priorities;
my $start = lsearch($legal_priorities, "P$p_start");
my $end;
$end = firstidx { $_ eq "P$p_end" } @$legal_priorities if defined $p_end;
$end = lsearch($legal_priorities, "P$p_end") if defined $p_end;
# If Pn doesn't exist explicitly, then we mean the nth priority.
if ($start == -1) {