boolean (@NotNull FileHistoryModel model, @Nullable VcsCommitMetadata detail, @NotNull AnActionEvent e) { FilePath filePath = e.getData(VcsDataKeys.FILE_PATH); if (filePath == null || filePath.isDirectory()) return false; if (detail != null) { VcsFileRevision fileRevision = model.createRevision(detail); if (VcsHistoryUtil.isEmpty(fileRevision)) return false; } return true; }