From 100576bd02cc706c21e6a1b55f563cb57c287e4d Mon Sep 17 00:00:00 2001 From: JT Date: Mon, 12 Jun 2023 22:04:51 -0700 Subject: [PATCH] Don't offer prereleases --- StabilityMatrix/Models/Packages/A3WebUI.cs | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/StabilityMatrix/Models/Packages/A3WebUI.cs b/StabilityMatrix/Models/Packages/A3WebUI.cs index c322aa9a..de43ab11 100644 --- a/StabilityMatrix/Models/Packages/A3WebUI.cs +++ b/StabilityMatrix/Models/Packages/A3WebUI.cs @@ -117,17 +117,17 @@ public class A3WebUI : BaseGitPackage if (isReleaseMode) { var allReleases = await GetAllReleases(); - return allReleases.Select(r => new PackageVersion {TagName = r.TagName!, ReleaseNotesMarkdown = r.Body}); + return allReleases.Where(r => r.Prerelease == false).Select(r => new PackageVersion + {TagName = r.TagName!, ReleaseNotesMarkdown = r.Body}); } - else // branch mode + + // else, branch mode + var allBranches = await GetAllBranches(); + return allBranches.Select(b => new PackageVersion { - var allBranches = await GetAllBranches(); - return allBranches.Select(b => new PackageVersion - { - TagName = $"{b.Name}", - ReleaseNotesMarkdown = string.Empty - }); - } + TagName = $"{b.Name}", + ReleaseNotesMarkdown = string.Empty + }); } public override async Task InstallPackage(IProgress? progress = null)