From: Frédéric Buclin Date: Fri, 14 May 2010 10:31:18 +0000 (+0200) Subject: Bug 565790: Unprivileged users cannot create bugs anymore X-Git-Tag: bugzilla-3.7.1~83 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=4d63354a757f487a391653a072661044d964e91f;p=thirdparty%2Fbugzilla.git Bug 565790: Unprivileged users cannot create bugs anymore r/a=mkanat --- diff --git a/enter_bug.cgi b/enter_bug.cgi index d85a9f060e..4aa6a29d9a 100755 --- a/enter_bug.cgi +++ b/enter_bug.cgi @@ -548,9 +548,8 @@ scalar(@statuses) || ThrowUserError('no_initial_bug_status'); # If the user has no privs... unless ($has_editbugs || $has_canconfirm) { # ... use UNCONFIRMED if available, else use the first status of the list. - my $bug_status = (grep { $_->name eq 'UNCONFIRMED' } @statuses) - ? 'UNCONFIRMED' : $statuses[0]->name; - @statuses = ($bug_status); + my ($unconfirmed) = grep { $_->name eq 'UNCONFIRMED' } @statuses; + @statuses = ($unconfirmed || $statuses[0]); } $vars->{'bug_status'} = \@statuses;