summaryrefslogtreecommitdiffstats
path: root/email_in.pl
diff options
context:
space:
mode:
authorFrédéric Buclin <LpSolit@gmail.com>2010-02-01 22:11:53 +0100
committerMax Kanat-Alexander <mkanat@bugzilla.org>2010-02-01 22:11:53 +0100
commitdb2e681e87ad1d15bc0c8f8ef08e222da7ea97c1 (patch)
tree860c86dcc050fdafc251468b645cf7a4d3a0325a /email_in.pl
parent2502c9ffb6687ab821ba09096f3f69ca17ebb42f (diff)
downloadbugzilla-db2e681e87ad1d15bc0c8f8ef08e222da7ea97c1.tar.gz
bugzilla-db2e681e87ad1d15bc0c8f8ef08e222da7ea97c1.tar.xz
Bug 534057: Auto-completion no longer works in email_in.pl
Patch by Frédéric Buclin <LpSolit@gmail.com> r/a=mkanat
Diffstat (limited to 'email_in.pl')
-rwxr-xr-xemail_in.pl11
1 files changed, 11 insertions, 0 deletions
diff --git a/email_in.pl b/email_in.pl
index 044c13040..c7b11d8a7 100755
--- a/email_in.pl
+++ b/email_in.pl
@@ -152,6 +152,17 @@ sub post_bug {
$fields->{$field} = undef if !exists $fields->{$field};
}
+ my ($retval, $non_conclusive_fields) =
+ Bugzilla::User::match_field({
+ 'assigned_to' => { 'type' => 'single' },
+ 'qa_contact' => { 'type' => 'single' },
+ 'cc' => { 'type' => 'multi' }
+ }, $fields, MATCH_SKIP_CONFIRM);
+
+ if ($retval != USER_MATCH_SUCCESS) {
+ ThrowUserError('user_match_too_many', {fields => $non_conclusive_fields});
+ }
+
my $bug = Bugzilla::Bug->create($fields);
debug_print("Created bug " . $bug->id);
return ($bug, $bug->comments->[0]);