@Override
  public void prepareRenaming(@NotNull PsiElement element, @NotNull String newName, @NotNull Map<PsiElement, String> allRenames, @NotNull SearchScope scope) {
    visitReferencedElements(element.getReferences(), psiElement -> {
      if (psiElement instanceof PsiNamedElement && psiElement != element) {
        allRenames.put(psiElement, newName);
      }
    });
  }
@Override
  public void prepareRenaming(@NotNull PsiElement element, @NotNull String newName, @NotNull Map<PsiElement, String> allRenames, @NotNull SearchScope scope)