mirror of
https://github.com/Crypto-Notepad/Crypto-Notepad.git
synced 2026-03-11 08:55:25 +00:00
Changed logic of checking updates
This commit is contained in:
parent
7483b6c7b2
commit
510547fd76
1 changed files with 4 additions and 3 deletions
|
|
@ -895,9 +895,9 @@ private void pictureBox13_Click(object sender, EventArgs e)
|
|||
string version = Application.ProductVersion;
|
||||
string exePath = Path.GetDirectoryName(Assembly.GetEntryAssembly().Location) + @"\";
|
||||
|
||||
int ver = Convert.ToInt32(version.Replace(".", "")), con = Convert.ToInt32(content.Replace(".", ""));
|
||||
int appVersion = Convert.ToInt32(version.Replace(".", "")), serverVersion = Convert.ToInt32(content.Replace(".", ""));
|
||||
|
||||
if (con != ver)
|
||||
if (serverVersion > appVersion)
|
||||
{
|
||||
MainMenu.Invoke((Action)delegate
|
||||
{
|
||||
|
|
@ -922,7 +922,7 @@ private void pictureBox13_Click(object sender, EventArgs e)
|
|||
});
|
||||
}
|
||||
|
||||
if (con == ver && autoCheck == true)
|
||||
if (serverVersion <= appVersion && autoCheck == true)
|
||||
{
|
||||
MainMenu.Invoke((Action)delegate
|
||||
{
|
||||
|
|
@ -932,6 +932,7 @@ private void pictureBox13_Click(object sender, EventArgs e)
|
|||
}
|
||||
});
|
||||
}
|
||||
|
||||
}
|
||||
catch
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in a new issue