From 65bce6c0dc399dcc0e2ae3dab3b934bdf8f806c7 Mon Sep 17 00:00:00 2001 From: Nadya Zabrodina Date: Fri, 31 Jan 2014 19:17:20 +0400 Subject: [PATCH] unnecessary 'else' removed --- .../src/org/zmlx/hg4idea/action/HgBranchesAction.java | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/plugins/hg4idea/src/org/zmlx/hg4idea/action/HgBranchesAction.java b/plugins/hg4idea/src/org/zmlx/hg4idea/action/HgBranchesAction.java index e808b73ee25e..61cf991c20a5 100644 --- a/plugins/hg4idea/src/org/zmlx/hg4idea/action/HgBranchesAction.java +++ b/plugins/hg4idea/src/org/zmlx/hg4idea/action/HgBranchesAction.java @@ -32,7 +32,7 @@ public class HgBranchesAction extends HgAbstractGlobalAction { @Override protected void execute(@NotNull Project project, @NotNull Collection repositories, @Nullable VirtualFile selectedRepo) { - HgRepository repository; + HgRepository repository = null; if (selectedRepo != null) { repository = HgUtil.getRepositoryManager(project).getRepositoryForRoot(selectedRepo); } @@ -41,9 +41,6 @@ public class HgBranchesAction extends HgAbstractGlobalAction { if (selectedRoot != null) { repository = HgUtil.getRepositoryManager(project).getRepositoryForRoot(selectedRoot); } - else { - return; - } } if (repository != null) { HgBranchPopup.getInstance(project, repository).asListPopup().showInFocusCenter();