aboutsummaryrefslogtreecommitdiffstats
path: root/src/main/java/de/pixart
diff options
context:
space:
mode:
authorChristian Schneppe <christian@pix-art.de>2018-11-23 12:28:27 +0100
committerChristian Schneppe <christian@pix-art.de>2018-11-23 12:28:27 +0100
commit7d584fbee00a5a74fbd14df6a9a98a47e112304e (patch)
tree479850b934a8da36e29c42c5117cfbc8384936ff /src/main/java/de/pixart
parentfce2177268b9bcdf3c8bccea161450db63d651a8 (diff)
refresh synced contacts even if offline
Diffstat (limited to 'src/main/java/de/pixart')
-rw-r--r--src/main/java/de/pixart/messenger/entities/Contact.java2
-rw-r--r--src/main/java/de/pixart/messenger/persistance/DatabaseBackend.java2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/main/java/de/pixart/messenger/entities/Contact.java b/src/main/java/de/pixart/messenger/entities/Contact.java
index e428362c6..17a6b1099 100644
--- a/src/main/java/de/pixart/messenger/entities/Contact.java
+++ b/src/main/java/de/pixart/messenger/entities/Contact.java
@@ -611,6 +611,6 @@ public class Contact implements ListItem, Blockable {
public static final int DIRTY_PUSH = 6;
public static final int DIRTY_DELETE = 7;
private static final int SYNCED_VIA_ADDRESSBOOK = 8;
- private static final int SYNCED_VIA_OTHER = 9;
+ public static final int SYNCED_VIA_OTHER = 9;
}
}
diff --git a/src/main/java/de/pixart/messenger/persistance/DatabaseBackend.java b/src/main/java/de/pixart/messenger/persistance/DatabaseBackend.java
index 7b316af70..8a6690c1b 100644
--- a/src/main/java/de/pixart/messenger/persistance/DatabaseBackend.java
+++ b/src/main/java/de/pixart/messenger/persistance/DatabaseBackend.java
@@ -928,7 +928,7 @@ public class DatabaseBackend extends SQLiteOpenHelper {
final SQLiteDatabase db = this.getWritableDatabase();
db.beginTransaction();
for (Contact contact : roster.getContacts()) {
- if (contact.getOption(Contact.Options.IN_ROSTER) || contact.getAvatarFilename() != null) {
+ if (contact.getOption(Contact.Options.IN_ROSTER) || contact.getAvatarFilename() != null || contact.getOption(Contact.Options.SYNCED_VIA_OTHER)) {
db.insert(Contact.TABLENAME, null, contact.getContentValues());
} else {
String where = Contact.ACCOUNT + "=? AND " + Contact.JID + "=?";