Don't include the same change twice in GetRelated.
If the order of commits was modified, while keeping the same change number, GetRelated would return both the new patch set and the old patch set. Instead of walking the children first, walk the parents first and exclude the changes from which the parents came. The changes are still used for generating the children queue, since there could be new children on top of the excluded ones. + Add test for listing related revisions. Change-Id: I297aef2cd966c3ea38501fc3d560d6776f58c09f
This commit is contained in:
@@ -974,7 +974,7 @@ public class ChangeJson {
|
||||
int tz;
|
||||
}
|
||||
|
||||
static class CommitInfo {
|
||||
public static class CommitInfo {
|
||||
final String kind = "gerritcodereview#commit";
|
||||
String commit;
|
||||
List<CommitInfo> parents;
|
||||
|
||||
Reference in New Issue
Block a user