use assembly file version instead of product version for update check
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
Imports System.IO
|
||||
Imports System.Net.Http
|
||||
Imports System.Reflection
|
||||
|
||||
Imports Newtonsoft.Json
|
||||
Imports Newtonsoft.Json.Converters
|
||||
@@ -21,10 +22,11 @@ Public Class AppUpdater
|
||||
Dim hasUpdate As Boolean = False
|
||||
|
||||
Try
|
||||
Dim appVersion As Version = Assembly.GetExecutingAssembly().GetName().Version
|
||||
Dim result = Await httpClient.GetStringAsync(UPDATE_URL)
|
||||
info = JsonConvert.DeserializeObject(Of UpdateInfo)(result)
|
||||
|
||||
If info IsNot Nothing AndAlso info.Version < New Version(Application.ProductVersion) Then
|
||||
If info IsNot Nothing AndAlso info.Version < appVersion Then
|
||||
hasUpdate = True
|
||||
End If
|
||||
Catch ex As Exception
|
||||
|
||||
Reference in New Issue
Block a user