mirror of
https://github.com/azaion/annotations.git
synced 2026-04-22 17:06:30 +00:00
check installer correctly
This commit is contained in:
@@ -63,7 +63,7 @@ public partial class Login
|
||||
if (installerVersion > localVersion)
|
||||
{
|
||||
TbStatus.Text = $"Updating from {localVersion} to {installerVersion}...";
|
||||
var (installerName, stream) = await _azaionApi.DownloadInstaller(_dirConfig?.SuiteInstallerDirectory ?? "");
|
||||
var (installerName, stream) = await _azaionApi.DownloadInstaller(_dirConfig?.IsStage ?? false);
|
||||
var localFileStream = new FileStream(installerName, FileMode.Create, FileAccess.Write);
|
||||
await stream.CopyToAsync(localFileStream);
|
||||
localFileStream.Close();
|
||||
@@ -164,9 +164,10 @@ public partial class Login
|
||||
private async Task<Version?> GetInstallerVer()
|
||||
{
|
||||
TbStatus.Text = "Checking for the newer version...";
|
||||
var installerDir = string.IsNullOrWhiteSpace(_dirConfig?.SuiteInstallerDirectory)
|
||||
var installerDir = _dirConfig?.IsStage ?? false
|
||||
? ConstantsLoader.SUITE_FOLDER
|
||||
: _dirConfig.SuiteInstallerDirectory;
|
||||
: ConstantsLoader.SUITE_STAGE_FOLDER;
|
||||
|
||||
var installerName = await _azaionApi.GetLastInstallerName(installerDir);
|
||||
try
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user