void (@NotNull Project project, @NotNull Consumer<? super VcsLogManager> action) { VcsLogManager logManager = VcsProjectLog.getInstance(project).getLogManager(); if (logManager != null) { action.consume(logManager); return; } ProjectLevelVcsManager.getInstance(project).runAfterInitialization(() -> { ApplicationManager.getApplication().invokeLater(() -> { VcsProjectLog.Companion.runWhenLogIsReady(project, manager -> { action.consume(manager); return Unit.INSTANCE; }); }, project.getDisposed()); }); }