private static @NotNull @Nls String getErrorMessage(GitRebaseCommandResult rebaseCommandResult,
                                                      GitCommandResult result,
                                                      String repoName) {
    String error;
    if (rebaseCommandResult.getFailureCause() instanceof VcsException editingFailureCause) {
      error = editingFailureCause.getMessage();
    }
    else {
      error = result.getErrorOutputAsHtmlString();
      LOG.info("Error rebasing root " + repoName + ": " + result.getErrorOutputAsJoinedString());
    }
    return error;
  }
private static @NotNull @Nls String getErrorMessage(GitRebaseCommandResult rebaseCommandResult,
                                                      GitCommandResult result,
                                                      String repoName)