From 21c92686705e558b3105cf3b8d9ac9ad8e46e4f6 Mon Sep 17 00:00:00 2001 From: Frédéric Buclin Date: Tue, 24 Sep 2013 11:29:49 +0200 Subject: Temporary fix for bug 916882: whitelist product and component when used with the changed* operators r/a=glob --- Bugzilla/Search/ClauseGroup.pm | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'Bugzilla/Search') 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); -- cgit v1.2.3-24-g4f1b