Skip to content
This repository was archived by the owner on Jun 21, 2023. It is now read-only.

Commit cd67be2

Browse files
committed
Remove unnecessary GetAbsolutePath method
1 parent 4727302 commit cd67be2

File tree

1 file changed

+1
-9
lines changed

1 file changed

+1
-9
lines changed

src/GitHub.App/Services/PullRequestEditorService.cs

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -90,13 +90,12 @@ public async Task<ITextView> OpenFile(
9090

9191
try
9292
{
93-
var fullPath = GetAbsolutePath(session.LocalRepository, relativePath);
9493
string fileName;
9594
string commitSha;
9695

9796
if (workingDirectory)
9897
{
99-
fileName = fullPath;
98+
fileName = Path.Combine(session.LocalRepository.LocalPath, relativePath);
10099
commitSha = null;
101100
}
102101
else
@@ -479,13 +478,6 @@ public static int FindNearestMatchingLine(IList<string> fromLines, IList<string>
479478
return matchingLine;
480479
}
481480

482-
static string GetAbsolutePath(LocalRepositoryModel localRepository, string relativePath)
483-
{
484-
var localPath = localRepository.LocalPath;
485-
relativePath = Paths.ToRelativePath(relativePath);
486-
return Path.Combine(localPath, relativePath);
487-
}
488-
489481
string GetText(IVsTextView textView)
490482
{
491483
IVsTextLines buffer;

0 commit comments

Comments
 (0)