private static boolean isLibraryFrameFilterSupported(@NotNull AnActionEvent e, Presentation presentation) {
    Object isSupported = presentation.getClientProperty(IS_LIBRARY_FRAME_FILTER_SUPPORTED);
    XDebugSession session = e.getData(XDebugSession.DATA_KEY);
    if (isSupported == null) {
      if (session == null) {
        // if session is null and isSupported is null - just return, it means that action created initially not in the xdebugger tab
        presentation.setVisible(false);
        return false;
      }

      isSupported = session.getDebugProcess().isLibraryFrameFilterSupported();
      presentation.putClientProperty(IS_LIBRARY_FRAME_FILTER_SUPPORTED, isSupported);
    }

    return Boolean.TRUE.equals(isSupported);
  }
private static boolean isLibraryFrameFilterSupported(@NotNull AnActionEvent e, Presentation presentation)