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
This commit is contained in:
Gabriele M
2017-08-31 17:29:48 +02:00
parent 17f35382d7
commit c50871c0dc

View File

@@ -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());