Maybe fixed updates this time

This commit is contained in:
JHubi1 2024-06-18 17:11:57 +02:00
parent 09fda2b004
commit 0401145987
No known key found for this signature in database
GPG Key ID: 7BF82570CBBBD050
2 changed files with 6 additions and 5 deletions

View File

@ -26,6 +26,7 @@ class _ScreenSettingsAboutState extends State<ScreenSettingsAbout> {
super.initState();
WidgetsFlutterBinding.ensureInitialized();
updatesSupported(setState, true);
setState(() {});
if (prefs!.getBool("checkUpdateOnSettingsOpen") ?? false) {
checkUpdate(setState);
}

View File

@ -43,10 +43,10 @@ Future<bool> updatesSupported(Function setState,
(installerApps
.contains((await InstallReferrer.app).packageName ?? ""))) {
returnValue = false;
if (await InstallReferrer.referrer ==
InstallationAppReferrer.androidDebug) {
returnValue = true;
}
// if (await InstallReferrer.referrer ==
// InstallationAppReferrer.androidDebug) {
// returnValue = true;
// }
}
if (!repoUrl.startsWith("https://github.com")) {
returnValue = false;
@ -114,7 +114,7 @@ void checkUpdate(Function setState) async {
});
} catch (e) {
setState(() {
updateStatus = "error";
updateStatus = "notAvailable";
updateLoading = false;
});
}