Added update handler.
This commit is contained in:
@@ -14,7 +14,7 @@ namespace BodyshopPartner.Utils
|
||||
{
|
||||
private static NLog.Logger logger = NLog.LogManager.GetCurrentClassLogger();
|
||||
|
||||
public const string UpdatePath = @"https://update.partner.imex.online";
|
||||
public const string UpdatePath = @"http://partner.imex.online/";
|
||||
|
||||
public static async Task<bool> AreUpdatesAvailable()
|
||||
{
|
||||
@@ -55,6 +55,7 @@ namespace BodyshopPartner.Utils
|
||||
{
|
||||
var updateInfo = await updateManager.CheckForUpdate();
|
||||
var releases = updateInfo.ReleasesToApply;
|
||||
logger.Debug("Applying releases", releases.ToString());
|
||||
await updateManager.DownloadReleases(releases, _ => { DownloadProgress = _; });
|
||||
await updateManager.ApplyReleases(updateInfo, _ => { InstallProgress = _; });
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user