From 59b7927fc6e0b5bc0796381f0eda4c7d18d17fc5 Mon Sep 17 00:00:00 2001 From: Serraniel Date: Mon, 27 Jul 2020 12:58:56 +0200 Subject: [PATCH] #34 Ignore pre-releases --- Discord Media Loader/Helper/VersionHelper.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Discord Media Loader/Helper/VersionHelper.cs b/Discord Media Loader/Helper/VersionHelper.cs index bce4af3..51b8178 100644 --- a/Discord Media Loader/Helper/VersionHelper.cs +++ b/Discord Media Loader/Helper/VersionHelper.cs @@ -17,7 +17,7 @@ namespace Discord_Media_Loader.Helper var github = new GitHubClient(new ProductHeaderValue("DiscordMedialLoader")); var tag = - (await github.Repository.Release.GetAll("Serraniel", "DiscordMediaLoader")).OrderByDescending(x => x.CreatedAt).First().TagName.Replace("v", "") ?? ""; + (await github.Repository.Release.GetAll("Serraniel", "DiscordMediaLoader")).Where(x => x.Prerelease == false).OrderByDescending(x => x.CreatedAt).First().TagName.Replace("v", "") ?? ""; var version = new Version(tag); return version;