@Override
  protected void invoke(@NotNull ActionContext context, @NotNull PsiClass element, @NotNull ModPsiUpdater updater) {

    final PsiField field = elementToRemove.getElement();
    if (field != null) {
      final Collection<PsiReference> all = ReferencesSearch.search(field).findAll();
      List<PsiElement> refs = ContainerUtil.map(all, ref -> updater.getWritable(ref.getElement()));
      PsiField writableField = updater.getWritable(field);

      final String loggerName = getLoggerName(element);
      for (PsiElement refElement : refs) {
        PsiReference ref = refElement.getReference();
        if (ref != null) {
          ref.handleElementRename(loggerName);
        }
      }

      writableField.delete();

      JavaCodeStyleManager.getInstance(context.project()).removeRedundantImports((PsiJavaFile)element.getContainingFile());
    }
    JavaCodeStyleManager.getInstance(context.project())
      .shortenClassReferences(Objects.requireNonNull(element.getModifierList()).addAnnotation(LombokClassNames.SLF_4_J));
  }
@Override
  protected void invoke(@NotNull ActionContext context, @NotNull PsiClass element, @NotNull ModPsiUpdater updater)