void (@NotNull ProgressIndicator indicator) { Collection<Change> changesInCommit; try { changesInCommit = AbstractDataGetter.getCommitDetails(data.getCommitDetailsGetter(), commit.getId(), commit.getRoot()).getChanges(); } catch (VcsException e) { String message = GitBundle.message("git.undo.action.could.not.load.changes.of.commit", commit.getId().asString()); LOG.warn(message, e); VcsNotifier.getInstance(project).notifyError(COULD_NOT_LOAD_CHANGES_OF_COMMIT, "", message); return; } GitResetOperation.OperationPresentation presentation = new GitResetOperation.OperationPresentation(); presentation.activityName = "git.undo.action.process"; presentation.operationTitle = "git.undo.action.operation"; presentation.notificationSuccess = "git.undo.action.successful.notification.message"; presentation.notificationFailure = "git.undo.action.failed.notification.title"; Map<GitRepository, Hash> targetCommits = singletonMap(repository, commit.getParents().get(0)); new GitResetOperation(project, targetCommits, SOFT, indicator, presentation).execute(); if (targetChangeList != null) { ChangeListManager changeListManager = ChangeListManager.getInstance(project); changeListManager.invokeAfterUpdateWithModal(true, GitBundle.message("git.undo.action.refreshing.changes.process"), () -> { Collection<Change> changes = GitUtil.findCorrespondentLocalChanges(changeListManager, changesInCommit); changeListManager.moveChangesTo(targetChangeList, changes.toArray(Change.EMPTY_CHANGE_ARRAY)); } ); } }