diff --git a/plugins/svn4idea/src/org/jetbrains/idea/svn/history/SvnChangeList.java b/plugins/svn4idea/src/org/jetbrains/idea/svn/history/SvnChangeList.java index 0ceade95ce36..f98d4de249fa 100644 --- a/plugins/svn4idea/src/org/jetbrains/idea/svn/history/SvnChangeList.java +++ b/plugins/svn4idea/src/org/jetbrains/idea/svn/history/SvnChangeList.java @@ -355,9 +355,10 @@ public class SvnChangeList implements CommittedChangeList { return Boolean.FALSE; } }); - final SvnRepositoryContentRevision contentRevision = - SvnRepositoryContentRevision.create(myVcs, myRepositoryRoot, path, localPath, getRevision(isBeforeRevision)); - return contentRevision; + long revision = getRevision(isBeforeRevision); + return localPath == null + ? SvnRepositoryContentRevision.createForRemotePath(myVcs, myRepositoryRoot, path, knownAsDirectory, revision) + : SvnRepositoryContentRevision.create(myVcs, myRepositoryRoot, path, localPath, revision); } public List getList() { diff --git a/plugins/svn4idea/src/org/jetbrains/idea/svn/history/SvnRepositoryContentRevision.java b/plugins/svn4idea/src/org/jetbrains/idea/svn/history/SvnRepositoryContentRevision.java index 8550a91d5a3c..d773027ac843 100644 --- a/plugins/svn4idea/src/org/jetbrains/idea/svn/history/SvnRepositoryContentRevision.java +++ b/plugins/svn4idea/src/org/jetbrains/idea/svn/history/SvnRepositoryContentRevision.java @@ -120,6 +120,15 @@ public class SvnRepositoryContentRevision implements ContentRevision, MarkerVcsC return create(vcs, SvnUtil.appendMultiParts(repositoryRoot, path), localPath, revision); } + public static SvnRepositoryContentRevision createForRemotePath(@NotNull SvnVcs vcs, + @NotNull String repositoryRoot, + @NotNull String path, + boolean isDirectory, + long revision) { + FilePath remotePath = VcsUtil.getFilePathOnNonLocal(SvnUtil.appendMultiParts(repositoryRoot, path), isDirectory); + return create(vcs, remotePath, remotePath, revision); + } + public static SvnRepositoryContentRevision create(@NotNull SvnVcs vcs, @NotNull String fullPath, @Nullable FilePath localPath, @@ -127,7 +136,7 @@ public class SvnRepositoryContentRevision implements ContentRevision, MarkerVcsC // TODO: Check if isDirectory = false always true for this method calls FilePath remotePath = VcsUtil.getFilePathOnNonLocal(fullPath, false); - return create(vcs, remotePath, localPath, revision); + return create(vcs, remotePath, localPath == null ? remotePath : localPath, revision); } public static SvnRepositoryContentRevision create(@NotNull SvnVcs vcs,