private void closeChanges()

in src/main/java/com/googlesource/gerrit/plugins/batch/BatchSubmitter.java [135:150]


  private void closeChanges(Batch.Destination dest)
      throws IOException, RepositoryNotFoundException, RestApiException, UpdateException,
          PermissionBackendException {
    if (dest.changes != null) {
      Project.NameKey project = Project.nameKey(dest.project);
      // TODO: Is using the first change in the batch for each dest the correct thing to do?
      Change firstInDest =
          notesFactory
              .createChecked(project, dest.changes.get(0).toPatchSetId().changeId())
              .getChange();
      SubmissionId submissionId = new SubmissionId(firstInDest);
      for (Batch.Change change : dest.changes) {
        closeChange(project, change.toPatchSetId(), dest.sha1, submissionId);
      }
    }
  }