public void perform() {
    final PsiNameIdentifierOwner element = getNamedElement();
    if (element != null) {
      final String name = element.getName();
      ApplicationManager.getApplication().runWriteAction(() -> {
        element.setName(myOldName);
      });
      new RenameProcessor(element.getProject(), element, name, false, false).run();
    }
  }
public void perform()