Commit 1f6e1616 authored by myk%mozilla.org's avatar myk%mozilla.org

Fix for bug 291391: allows users to rerequest set flags even if they don't have…

Fix for bug 291391: allows users to rerequest set flags even if they don't have the privilege to set them; r=lpsolit; a=myk
parent 993f0b35
...@@ -320,9 +320,9 @@ sub validate { ...@@ -320,9 +320,9 @@ sub validate {
# - The flag is unchanged # - The flag is unchanged
next if ($status eq $flag->{status}); next if ($status eq $flag->{status});
# - User in the $request_gid group can clear pending requests # - User in the $request_gid group can clear pending requests and set flags
next if ($status eq 'X' # and can rerequest set flags.
&& $flag->{status} eq '?' next if (($status eq 'X' || $status eq '?')
&& (!$flag->{type}->{request_gid} && (!$flag->{type}->{request_gid}
|| $user->in_group(&::GroupIdToName($flag->{type}->{request_gid})))); || $user->in_group(&::GroupIdToName($flag->{type}->{request_gid}))));
......
...@@ -442,12 +442,10 @@ ...@@ -442,12 +442,10 @@
[% title = "Flag Modification Denied" %] [% title = "Flag Modification Denied" %]
You tried to [% IF status == "+" %] grant [% ELSIF status == "-" %] deny You tried to [% IF status == "+" %] grant [% ELSIF status == "-" %] deny
[% ELSIF status == "X" %] clear [% ELSE %] request [% END %] [% ELSIF status == "X" %] clear [% ELSE %] request [% END %]
<code>[% name FILTER html %]</code> <code>[% name FILTER html %]
[% IF status == "?" && old_status != "X" %], but this flag is already [% IF status == "X" %][% old_status FILTER html %][% END %]</code>.
set[% END %].
Only a sufficiently empowered user [% IF status == "X" %] or the user who Only a sufficiently empowered user can make this change.
set <code>[% name FILTER html %][% old_status FILTER html %]</code> in
the first place [% END %] can make this change.
[% ELSIF error == "format_not_found" %] [% ELSIF error == "format_not_found" %]
[% title = "Format Not Found" %] [% title = "Format Not Found" %]
......
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