void (@NotNull Project project, @NotNull Collection<GitRepository> selectedRepositories) { ModalityState modality = ModalityState.defaultModalityState(); TransactionGuard.getInstance().assertWriteSafeContext(modality); List<GitRepository> repositories = new ArrayList<>(selectedRepositories); ModalityUiUtil.invokeLaterIfNeeded(modality, project.getDisposed(), () -> { new GitPushAfterCommitDialog(project, repositories, null).showOrPush(); }); }