From af18624b898fc0cd69354e0bc1a73ce30353091e Mon Sep 17 00:00:00 2001 From: Kirill Likhodedov Date: Thu, 6 Nov 2014 15:26:37 +0300 Subject: [PATCH] [git] cleanup --- .../src/git4idea/actions/GitRepositoryAction.java | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/plugins/git4idea/src/git4idea/actions/GitRepositoryAction.java b/plugins/git4idea/src/git4idea/actions/GitRepositoryAction.java index eb30f463ac7c..042b651c6840 100644 --- a/plugins/git4idea/src/git4idea/actions/GitRepositoryAction.java +++ b/plugins/git4idea/src/git4idea/actions/GitRepositoryAction.java @@ -18,7 +18,6 @@ package git4idea.actions; import com.intellij.openapi.actionSystem.ActionPlaces; import com.intellij.openapi.actionSystem.AnActionEvent; import com.intellij.openapi.actionSystem.CommonDataKeys; -import com.intellij.openapi.actionSystem.DataContext; import com.intellij.openapi.fileEditor.FileDocumentManager; import com.intellij.openapi.project.DumbAwareAction; import com.intellij.openapi.project.Project; @@ -54,11 +53,7 @@ public abstract class GitRepositoryAction extends DumbAwareAction { public void actionPerformed(@NotNull final AnActionEvent e) { myDelayedTasks.clear(); FileDocumentManager.getInstance().saveAllDocuments(); - DataContext dataContext = e.getDataContext(); - final Project project = CommonDataKeys.PROJECT.getData(dataContext); - if (project == null) { - return; - } + final Project project = e.getRequiredData(CommonDataKeys.PROJECT); GitVcs vcs = GitVcs.getInstance(project); final List roots = getGitRoots(project, vcs); if (roots == null) return; @@ -187,9 +182,6 @@ public abstract class GitRepositoryAction extends DumbAwareAction { final Set affectedRoots, List exceptions) throws VcsException; - /** - * {@inheritDoc} - */ @Override public void update(final AnActionEvent e) { super.update(e);