public static void markActionInvoked(@NotNull Project project,
                                       @NotNull Editor editor,
                                       @NotNull IntentionAction action) {
    int offset = editor instanceof EditorEx ex ? ex.getExpectedCaretOffset() : editor.getCaretModel().getOffset();

    List<HighlightInfo> infos = new ArrayList<>();
    DaemonCodeAnalyzerImpl.processHighlightsNearOffset(editor.getDocument(), project, HighlightSeverity.INFORMATION, offset, true,
                                                       new CommonProcessors.CollectProcessor<>(infos));
    for (HighlightInfo info : infos) {
      info.unregisterQuickFix(action1 -> action1 == action);
    }
  }
public static void markActionInvoked(@NotNull Project project,
                                       @NotNull Editor editor,
                                       @NotNull IntentionAction action)