From 4d63354a757f487a391653a072661044d964e91f Mon Sep 17 00:00:00 2001 From: Frédéric Buclin Date: Fri, 14 May 2010 12:31:18 +0200 Subject: Bug 565790: Unprivileged users cannot create bugs anymore r/a=mkanat --- enter_bug.cgi | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'enter_bug.cgi') diff --git a/enter_bug.cgi b/enter_bug.cgi index d85a9f060..4aa6a29d9 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; -- cgit v1.2.3-24-g4f1b