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

Commit

Permalink
fix comments
Browse files Browse the repository at this point in the history
  • Loading branch information
NBull92 committed Oct 25, 2023
1 parent b0b7d91 commit 30a19ea
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/Squirrel/Sources/GitlabSource.cs
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ public GitlabSource(string repoUrl, string accessToken, bool upcomingRelease, IF
public Task DownloadReleaseEntry(ReleaseEntry releaseEntry, string localFile, Action<int> progress)
{
if (Release == null) {
throw new InvalidOperationException("No GiitLab Release specified. Call GetReleaseFeed or set " +
throw new InvalidOperationException("No GitLab Release specified. Call GetReleaseFeed or set " +
"GitLabSource.Release before calling this function.");
}

Expand All @@ -172,12 +172,12 @@ public async Task<ReleaseEntry[]> GetReleaseFeed(Guid? stagingId = null, Release
{
var releases = await GetReleases(UpcomingRelease).ConfigureAwait(false);
if (releases == null || releases.Count() == 0)
throw new Exception($"No GitHub releases found at '{RepoUri}'.");
throw new Exception($"No Gitlab releases found at '{RepoUri}'.");

// CS: we 'cache' the release here, so subsequent calls to DownloadReleaseEntry
// will download assets from the same release in which we returned ReleaseEntry's
// from. A better architecture would be to return an array of "GithubReleaseEntry"
// containing a reference to the GithubReleaseAsset instead.
// from. A better architecture would be to return an array of "GitlabReleaseEntry"
// containing a reference to the GitlabReleaseAsset instead.
Release = releases.First();

var assetUrl = GetAssetUrlFromName(Release, "RELEASES");
Expand All @@ -196,7 +196,7 @@ protected virtual string GetAssetUrlFromName(GitlabRelease release, string asset
{
if (release.Assets == null || release.Assets.Count == 0)
{
throw new ArgumentException($"No assets found in Github Release '{release.Name}'.");
throw new ArgumentException($"No assets found in Gitlab Release '{release.Name}'.");
}

GitlabReleaseLink packageFile =
Expand Down

0 comments on commit 30a19ea

Please sign in to comment.