mirror of
https://codeberg.org/Freeyourgadget/Gadgetbridge
synced 2024-08-30 19:15:54 +02:00
Fix checking for up-to-date User and Device attributes
This commit is contained in:
parent
65d973401a
commit
b3984a409c
@ -196,7 +196,7 @@ public class DBHelper {
|
|||||||
private static boolean hasUpToDateUserAttributes(List<UserAttributes> userAttributes, ActivityUser prefsUser) {
|
private static boolean hasUpToDateUserAttributes(List<UserAttributes> userAttributes, ActivityUser prefsUser) {
|
||||||
for (UserAttributes attr : userAttributes) {
|
for (UserAttributes attr : userAttributes) {
|
||||||
if (!isValidNow(attr)) {
|
if (!isValidNow(attr)) {
|
||||||
return false;
|
continue;
|
||||||
}
|
}
|
||||||
if (isEqual(attr, prefsUser)) {
|
if (isEqual(attr, prefsUser)) {
|
||||||
return true;
|
return true;
|
||||||
@ -311,7 +311,7 @@ public class DBHelper {
|
|||||||
private static boolean hasUpToDateDeviceAttributes(List<DeviceAttributes> deviceAttributes, GBDevice gbDevice) {
|
private static boolean hasUpToDateDeviceAttributes(List<DeviceAttributes> deviceAttributes, GBDevice gbDevice) {
|
||||||
for (DeviceAttributes attr : deviceAttributes) {
|
for (DeviceAttributes attr : deviceAttributes) {
|
||||||
if (!isValidNow(attr)) {
|
if (!isValidNow(attr)) {
|
||||||
return false;
|
continue;
|
||||||
}
|
}
|
||||||
if (isEqual(attr, gbDevice)) {
|
if (isEqual(attr, gbDevice)) {
|
||||||
return true;
|
return true;
|
||||||
|
Loading…
Reference in New Issue
Block a user