Commit d758e50a authored by Reed Loden's avatar Reed Loden

Bug 537887 - "The flag setter should be able to unset a flag even if not in the request group"

[r=LpSolit a=LpSolit]
parent ed751860
......@@ -731,10 +731,12 @@ sub _check_setter {
# Make sure the user is authorized to modify flags, see bug 180879:
# - The flag exists and is unchanged.
# - The flag setter can unset flag.
# - Users in the request_group can clear pending requests and set flags
# and can rerequest set flags.
# - Users in the grant_group can set/clear flags, including "+" and "-".
unless (($status eq $self->{_old_status})
|| ($status eq 'X' && $setter->id == Bugzilla->user->id)
|| (($status eq 'X' || $status eq '?')
&& $setter->can_request_flag($self->type))
|| $setter->can_set_flag($self->type))
......
......@@ -66,7 +66,7 @@
onchange="toggleRequesteeField(this);"
class="flag_select">
[%# Only display statuses the user is allowed to set. %]
[% IF user.can_request_flag(type) %]
[% IF user.can_request_flag(type) || flag.setter_id == user.id %]
<option value="X"></option>
[% END %]
[% IF type.is_active %]
......@@ -210,4 +210,4 @@
</td>
[% END %]
</tr>
[% END %]
\ No newline at end of file
[% END %]
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment