aboutsummaryrefslogtreecommitdiffstats
path: root/Bugzilla/Search
diff options
context:
space:
mode:
authorFrédéric Buclin <LpSolit@gmail.com>2013-09-24 11:29:49 +0200
committerFrédéric Buclin <LpSolit@gmail.com>2013-09-24 11:29:49 +0200
commit21c92686705e558b3105cf3b8d9ac9ad8e46e4f6 (patch)
tree9d0c57ccb45d60d4eedf3cfb6e01055d805bd173 /Bugzilla/Search
parent9ddb229412d652238dabd39f8c46d2e81c0466f6 (diff)
downloadbugs-21c92686705e558b3105cf3b8d9ac9ad8e46e4f6.tar
bugs-21c92686705e558b3105cf3b8d9ac9ad8e46e4f6.tar.gz
bugs-21c92686705e558b3105cf3b8d9ac9ad8e46e4f6.tar.bz2
bugs-21c92686705e558b3105cf3b8d9ac9ad8e46e4f6.tar.xz
bugs-21c92686705e558b3105cf3b8d9ac9ad8e46e4f6.zip
Temporary fix for bug 916882: whitelist product and component when used with the changed* operators
r/a=glob
Diffstat (limited to 'Bugzilla/Search')
-rw-r--r--Bugzilla/Search/ClauseGroup.pm5
1 files changed, 4 insertions, 1 deletions
diff --git a/Bugzilla/Search/ClauseGroup.pm b/Bugzilla/Search/ClauseGroup.pm
index a50dc4fb3..eb306525c 100644
--- a/Bugzilla/Search/ClauseGroup.pm
+++ b/Bugzilla/Search/ClauseGroup.pm
@@ -66,7 +66,10 @@ sub add {
# Unsupported fields
if (grep { $_ eq $field } UNSUPPORTED_FIELDS ) {
- ThrowUserError('search_grouped_field_invalid', { field => $field });
+ # XXX - Hack till bug 916882 is fixed.
+ my $operator = scalar(@args) == 3 ? $args[1] : $args[0]->{operator};
+ ThrowUserError('search_grouped_field_invalid', { field => $field })
+ unless (($field eq 'product' || $field eq 'component') && $operator =~ /^changed/);
}
$self->SUPER::add(@args);