diff --git a/ProjectLighthouse.Servers.Website/Pages/Layouts/BaseLayout.cshtml b/ProjectLighthouse.Servers.Website/Pages/Layouts/BaseLayout.cshtml
index 78d36de4..a755562c 100644
--- a/ProjectLighthouse.Servers.Website/Pages/Layouts/BaseLayout.cshtml
+++ b/ProjectLighthouse.Servers.Website/Pages/Layouts/BaseLayout.cshtml
@@ -192,7 +192,7 @@
@{
- string? remoteUrl = VersionHelper.DetermineRemoteUrl();
+ string? remoteUrl = VersionHelper.DetermineRemoteUrl(false);
}
@Model.Translate(BaseLayoutStrings.GeneratedBy, VersionHelper.FullVersion)
diff --git a/ProjectLighthouse/Helpers/VersionHelper.cs b/ProjectLighthouse/Helpers/VersionHelper.cs
index 3262437d..82222e09 100644
--- a/ProjectLighthouse/Helpers/VersionHelper.cs
+++ b/ProjectLighthouse/Helpers/VersionHelper.cs
@@ -52,7 +52,8 @@ public static class VersionHelper
/// Determines the URL of the git remote. This doesn't return a complete URL and it's only really used for the
/// "Source Code" hyperlink in the BaseLayout. Use this with caution.
///
- public static string? DetermineRemoteUrl()
+ /// Include the "https://" prefix in the returned URL.
+ public static string? DetermineRemoteUrl(bool includePrefix = true)
{
string? remoteUnparsedUrl = null;
string? remoteParsedUrl = null;
@@ -66,7 +67,9 @@ public static class VersionHelper
}
else if (remoteUnparsedUrl.Contains("https://"))
{
- remoteParsedUrl = remoteUnparsedUrl.Replace("https://", "").Split(".git").FirstOrDefault();
+ remoteParsedUrl = includePrefix
+ ? remoteUnparsedUrl.Split(".git").FirstOrDefault()
+ : remoteUnparsedUrl.Replace("https://", "").Split(".git").FirstOrDefault();
}
return remoteParsedUrl;