Skip unnecessary Change.Id parsing from Refs
No need to parse Ref.getName()->ChangeId in VisibleRefFilter if we are not asking for any change-refs. Change-Id: I1e0604f3e80fadc966400a732df1fc0fe71df4d9
This commit is contained in:
@@ -79,7 +79,7 @@ public class VisibleRefFilter extends AbstractAdvertiseRefsHook {
|
|||||||
if (PatchSet.isRef(ref.getName())) {
|
if (PatchSet.isRef(ref.getName())) {
|
||||||
// Reference to a patch set is visible if the change is visible.
|
// Reference to a patch set is visible if the change is visible.
|
||||||
//
|
//
|
||||||
if (visibleChanges.contains(Change.Id.fromRef(ref.getName()))) {
|
if (showChanges && visibleChanges.contains(Change.Id.fromRef(ref.getName()))) {
|
||||||
result.put(ref.getName(), ref);
|
result.put(ref.getName(), ref);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user