XDebugSession (@NotNull AnActionEvent e) { XDebugSession session = e.getData(XDebugSession.DATA_KEY); if (session == null) { Project project = e.getProject(); if (project != null) { session = XDebuggerManager.getInstance(project).getCurrentSession(); } } return session; }