mirror of
https://github.com/ImranR98/Obtainium.git
synced 2025-08-19 13:09:30 +02:00
fix race condition when checking updates
This commit is contained in:
@@ -902,7 +902,7 @@ class AppsProvider with ChangeNotifier {
|
|||||||
if (currentApp.preferredApkIndex < newApp.apkUrls.length) {
|
if (currentApp.preferredApkIndex < newApp.apkUrls.length) {
|
||||||
newApp.preferredApkIndex = currentApp.preferredApkIndex;
|
newApp.preferredApkIndex = currentApp.preferredApkIndex;
|
||||||
}
|
}
|
||||||
await saveApps([newApp]);
|
if (apps.containsKey(appId)) await saveApps([newApp]);
|
||||||
return newApp.latestVersion != currentApp.latestVersion ? newApp : null;
|
return newApp.latestVersion != currentApp.latestVersion ? newApp : null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user