Skip to content
This repository was archived by the owner on Dec 5, 2024. It is now read-only.

Commit 1907d34

Browse files
Setting CloneUrl to be a public read/private write property
1 parent 89406f7 commit 1907d34

File tree

1 file changed

+4
-11
lines changed

1 file changed

+4
-11
lines changed

src/GitHub.Api/Git/Repository.cs

Lines changed: 4 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -222,21 +222,14 @@ public ConfigRemote? CurrentRemote
222222
}
223223
}
224224

225-
public UriString CloneUrl
226-
{
227-
get
228-
{
229-
if (CurrentRemote.HasValue && CurrentRemote.Value.Url != null)
230-
return new UriString(CurrentRemote.Value.Url).ToRepositoryUrl();
231-
232-
return null;
233-
}
234-
}
235-
225+
public UriString CloneUrl { get; private set; }
236226

237227
public string Name { get; private set; }
228+
238229
public NPath LocalPath { get; private set; }
230+
239231
public string Owner => CloneUrl?.Owner ?? null;
232+
240233
public bool IsGitHub { get { return HostAddress.IsGitHubDotCom(CloneUrl); } }
241234

242235
internal string DebuggerDisplay => String.Format(

0 commit comments

Comments
 (0)