summaryrefslogtreecommitdiffstats
path: root/post_bug.cgi
diff options
context:
space:
mode:
Diffstat (limited to 'post_bug.cgi')
-rwxr-xr-xpost_bug.cgi10
1 files changed, 5 insertions, 5 deletions
diff --git a/post_bug.cgi b/post_bug.cgi
index fbfdf27f7..957e7b75f 100755
--- a/post_bug.cgi
+++ b/post_bug.cgi
@@ -124,8 +124,8 @@ $template->process($format->{'template'}, $vars, \$comment)
|| ThrowTemplateError($template->error());
# Include custom fields editable on bug creation.
-my @custom_bug_fields = grep {$_->type != FIELD_TYPE_MULTI_SELECT}
- Bugzilla->get_fields({ custom => 1, obsolete => 0, enter_bug => 1 });
+my @custom_bug_fields = grep {$_->type != FIELD_TYPE_MULTI_SELECT && $_->enter_bug}
+ Bugzilla->active_custom_fields;
# Undefined custom fields are ignored to ensure they will get their default
# value (e.g. "---" for custom single select fields).
@@ -167,9 +167,9 @@ $bug_params{'cc'} = [$cgi->param('cc')];
$bug_params{'groups'} = \@selected_groups;
$bug_params{'comment'} = $comment;
-my @multi_selects = Bugzilla->get_fields(
- { type => FIELD_TYPE_MULTI_SELECT, custom => 1, obsolete => 0,
- enter_bug => 1 });
+my @multi_selects = grep {$_->type == FIELD_TYPE_MULTI_SELECT && $_->enter_bug}
+ Bugzilla->active_custom_fields;
+
foreach my $field (@multi_selects) {
$bug_params{$field->name} = [$cgi->param($field->name)];
}