From d6e22e1659e0b96b828750587b408f677f6011e5 Mon Sep 17 00:00:00 2001 From: Aabed Khan <39409020+TheAabedKhan@users.noreply.github.com> Date: Sun, 11 Jun 2023 10:32:18 +0545 Subject: [PATCH] fix: fixed bug #890 The _latestManagerVersion returns empty string when comparing to the currentVersion. So, calling the _managerAPI.getLatestManagerVersion() before comparing fixes the logic and boolean is returned accordingly. --- lib/ui/views/home/home_viewmodel.dart | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/ui/views/home/home_viewmodel.dart b/lib/ui/views/home/home_viewmodel.dart index 090ac30e74..12757159de 100644 --- a/lib/ui/views/home/home_viewmodel.dart +++ b/lib/ui/views/home/home_viewmodel.dart @@ -113,7 +113,8 @@ class HomeViewModel extends BaseViewModel { Future hasManagerUpdates() async { String currentVersion = await _managerAPI.getCurrentManagerVersion(); - + _latestManagerVersion = await _managerAPI.getLatestManagerVersion(); + // add v to current version if (!currentVersion.startsWith('v')) { currentVersion = 'v$currentVersion';