Merge branch 'stable-2.13'
* stable-2.13: Allow user with maintain server permissions to find any change Change-Id: Ie8ccf29175d61fd6f7a1c140bf1c65ad409eea53
This commit is contained in:
commit
9146a9508f
@ -80,10 +80,13 @@ public class ChangeArgumentParser {
|
||||
List<ChangeControl> matched =
|
||||
useIndex ? changeFinder.find(id, currentUser) : changeFromNotesFactory(id, currentUser);
|
||||
List<ChangeControl> toAdd = new ArrayList<>(changes.size());
|
||||
boolean canMaintainServer =
|
||||
currentUser.isIdentifiedUser()
|
||||
&& currentUser.asIdentifiedUser().getCapabilities().canMaintainServer();
|
||||
for (ChangeControl ctl : matched) {
|
||||
if (!changes.containsKey(ctl.getId())
|
||||
&& inProject(projectControl, ctl.getProject())
|
||||
&& ctl.isVisible(db)) {
|
||||
&& (canMaintainServer || ctl.isVisible(db))) {
|
||||
toAdd.add(ctl);
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user