Skip to content

Commit ad40d36

Browse files
committed
Correct repos
1 parent 06410da commit ad40d36

File tree

2 files changed

+9
-10
lines changed

2 files changed

+9
-10
lines changed

Flow.Launcher.Core/Updater.cs

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -22,21 +22,20 @@ namespace Flow.Launcher.Core
2222
{
2323
public class Updater
2424
{
25+
public string GitHubReleaseRepository { get; }
26+
public string GitHubPrereleaseRepository { get; }
27+
2528
public bool UpdateToPrerelease { get; set; }
26-
27-
// TODO
28-
public const string ReleaseRepository = "https://github.com/Flow-Launcher/Flow.Launcher";
29-
public const string PrereleaseRepository = "https://github.com/Flow-Launcher/Prereleases";
30-
31-
// TODO
32-
public string GitHubRepository => UpdateToPrerelease ? PrereleaseRepository : ReleaseRepository;
29+
30+
public string GitHubRepository => UpdateToPrerelease ? GitHubPrereleaseRepository : GitHubReleaseRepository;
3331

3432
private readonly IPublicAPI _api;
3533

36-
public Updater(IPublicAPI publicAPI, string gitHubRepository)
34+
public Updater(IPublicAPI publicAPI, string gitHubReleaseRepository, string gitHubPrereleaseRepository)
3735
{
3836
_api = publicAPI;
39-
GitHubRepository = gitHubRepository;
37+
GitHubReleaseRepository = gitHubReleaseRepository;
38+
GitHubPrereleaseRepository = gitHubPrereleaseRepository;
4039
}
4140

4241
private SemaphoreSlim UpdateLock { get; } = new SemaphoreSlim(1);

Flow.Launcher/App.xaml.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ public App()
5555
.UseContentRoot(AppContext.BaseDirectory)
5656
.ConfigureServices(services => services
5757
.AddSingleton(_ => _settings)
58-
.AddSingleton(sp => new Updater(sp.GetRequiredService<IPublicAPI>(), Launcher.Properties.Settings.Default.GithubRepo))
58+
.AddSingleton(sp => new Updater(sp.GetRequiredService<IPublicAPI>(), Launcher.Properties.Settings.Default.GithubRepo, Launcher.Properties.Settings.Default.PrereleaseRepo))
5959
.AddSingleton<Portable>()
6060
.AddSingleton<SettingWindowViewModel>()
6161
.AddSingleton<IAlphabet, PinyinAlphabet>()

0 commit comments

Comments
 (0)