summaryrefslogtreecommitdiffstats
path: root/Bugzilla
diff options
context:
space:
mode:
authormkanat%bugzilla.org <>2009-07-20 06:10:55 +0200
committermkanat%bugzilla.org <>2009-07-20 06:10:55 +0200
commitd7e5d9fdab1be995187d62e93fa7ebdc7a2ea439 (patch)
tree3a0efbd325b5df66d4a24775b6cd0da9a845617b /Bugzilla
parent75e516184ed75b1daecda4c796c86f81c63da982 (diff)
downloadbugzilla-d7e5d9fdab1be995187d62e93fa7ebdc7a2ea439.tar.gz
bugzilla-d7e5d9fdab1be995187d62e93fa7ebdc7a2ea439.tar.xz
Bug 314364: Make QuickSearch use "matches" for comment searches instead of "substring"
Patch by Max Kanat-Alexander <mkanat@bugzilla.org> r=wicked, a=mkanat
Diffstat (limited to 'Bugzilla')
-rw-r--r--Bugzilla/Config/Query.pm7
-rw-r--r--Bugzilla/Search/Quicksearch.pm13
2 files changed, 3 insertions, 17 deletions
diff --git a/Bugzilla/Config/Query.pm b/Bugzilla/Config/Query.pm
index fbfdb4c22..6479db8ce 100644
--- a/Bugzilla/Config/Query.pm
+++ b/Bugzilla/Config/Query.pm
@@ -68,13 +68,6 @@ sub get_param_list {
},
{
- name => 'quicksearch_comment_cutoff',
- type => 't',
- default => '4',
- checker => \&check_numeric
- },
-
- {
name => 'specific_search_allow_empty_words',
type => 'b',
default => 1
diff --git a/Bugzilla/Search/Quicksearch.pm b/Bugzilla/Search/Quicksearch.pm
index 70b5e2f2c..5f5eae95f 100644
--- a/Bugzilla/Search/Quicksearch.pm
+++ b/Bugzilla/Search/Quicksearch.pm
@@ -167,8 +167,6 @@ sub quicksearch {
$searchstring =~ s/\s+NOT\s+/ -/g;
my @words = splitString($searchstring);
- my $searchComments =
- $#words < Bugzilla->params->{'quicksearch_comment_cutoff'};
my @openStates = BUG_STATE_OPEN;
my @closedStates;
my @unknownFields;
@@ -245,10 +243,8 @@ sub quicksearch {
}
}
elsif ($firstChar eq '#') {
- addChart('short_desc', 'anywords', $baseWord, $negate);
- if ($searchComments) {
- addChart('longdesc', 'anywords', $baseWord, $negate);
- }
+ addChart('short_desc', 'substring', $baseWord, $negate);
+ addChart('content', 'matches', $baseWord, $negate);
}
elsif ($firstChar eq ':') {
foreach (@subWords) {
@@ -386,10 +382,7 @@ sub quicksearch {
addChart('status_whiteboard', 'substring',
$word, $negate);
}
- if ($searchComments) {
- addChart('longdesc', 'substring',
- $word, $negate);
- }
+ addChart('content', 'matches', $word, $negate);
}
# URL field (for IP addrs, host.names,
# scheme://urls)