in src/main/java/com/googlesource/gerrit/plugins/batch/Batch.java [89:101]
public Destination getDestination(BranchNameKey branch) {
if (destinations == null) {
destinations = new ArrayList<>();
}
Destination dest = getExistingDestination(branch);
if (dest == null) {
dest = new Destination();
dest.project = branch.project().get();
dest.ref = branch.branch();
destinations.add(dest);
}
return dest;
}