diff options
author | Gabriele M <moto.falcon.git@gmail.com> | 2017-08-31 17:29:48 +0200 |
---|---|---|
committer | Gabriele M <moto.falcon.git@gmail.com> | 2017-08-31 17:29:48 +0200 |
commit | c50871c0dc634facf5dd1d3c13956f675625637e (patch) | |
tree | 758c8eda7fd65aae95a2464c2a15b2abced41e66 | |
parent | 17f35382d72ec1dc5753bd97ee635ff32171912e (diff) | |
download | android_packages_apps_Updater-c50871c0dc634facf5dd1d3c13956f675625637e.tar.gz android_packages_apps_Updater-c50871c0dc634facf5dd1d3c13956f675625637e.tar.bz2 android_packages_apps_Updater-c50871c0dc634facf5dd1d3c13956f675625637e.zip |
Allow to keep incompatible updates when parsing jsons
The condition was wrong and incompatible updates were always
discarded regardless of the flag passed.
Change-Id: Iefc2d64b841921eb77a9f73cf374b63b477d2588
-rw-r--r-- | src/org/lineageos/updater/misc/Utils.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/org/lineageos/updater/misc/Utils.java b/src/org/lineageos/updater/misc/Utils.java index f15be50..7713993 100644 --- a/src/org/lineageos/updater/misc/Utils.java +++ b/src/org/lineageos/updater/misc/Utils.java @@ -130,7 +130,7 @@ public class Utils { } try { UpdateInfo update = parseJsonUpdate(updatesList.getJSONObject(i)); - if (compatibleOnly && isCompatible(update)) { + if (!compatibleOnly || isCompatible(update)) { updates.add(update); } else { Log.d(TAG, "Ignoring incompatible update " + update.getName()); |