public static void temporallyRevertChanges(final TextRange signatureRange,
                                             final Document document,
                                             final String initialSignature,
                                             Project project) {
    WriteCommandAction.runWriteCommandAction(project, () -> {
      document.replaceString(signatureRange.getStartOffset(), signatureRange.getEndOffset(), initialSignature);
      PsiDocumentManager.getInstance(project).commitDocument(document);
    });
  }
public static void temporallyRevertChanges(final TextRange signatureRange,
                                             final Document document,
                                             final String initialSignature,
                                             Project project)