From 756f0ed3f5ac5965d60e9c39b18eff14b576d9bb Mon Sep 17 00:00:00 2001 From: Oleg Shpynov Date: Tue, 25 Oct 2011 16:54:40 +0400 Subject: [PATCH] Fix GithubRebase action to use new Git API --- .../org/jetbrains/plugins/github/GithubRebaseAction.java | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/plugins/github/src/org/jetbrains/plugins/github/GithubRebaseAction.java b/plugins/github/src/org/jetbrains/plugins/github/GithubRebaseAction.java index 740d8b4869fb..910079479ff0 100644 --- a/plugins/github/src/org/jetbrains/plugins/github/GithubRebaseAction.java +++ b/plugins/github/src/org/jetbrains/plugins/github/GithubRebaseAction.java @@ -132,10 +132,11 @@ public class GithubRebaseAction extends DumbAwareAction { // Check that corresponding remote branch is configured for the fork origin repo final Ref remoteForForkParentRepo = new Ref(); for (GitRemote gitRemote : gitRepository.getRemotes()) { - final String fetchUrl = gitRemote.getFetchRefSpec(); - if (fetchUrl.endsWith(parent + ".git")) { - remoteForForkParentRepo.set(gitRemote.getName()); - break; + for (String url : gitRemote.getUrls()) { + if (url.endsWith(parent + ".git")) { + remoteForForkParentRepo.set(gitRemote.getName()); + break; + } } } if (remoteForForkParentRepo.isNull()){