aboutsummaryrefslogtreecommitdiffstats
path: root/src/eu/siacs/conversations/persistance/DatabaseBackend.java
diff options
context:
space:
mode:
authorDaniel Gultsch <daniel@gultsch.de>2014-03-14 20:19:58 +0100
committerDaniel Gultsch <daniel@gultsch.de>2014-03-14 20:19:58 +0100
commit29e128513d3abdaae829e99ec9dfab1b0a0d84cd (patch)
treeaa922340ee478b38b40091554ad62087853cd2bd /src/eu/siacs/conversations/persistance/DatabaseBackend.java
parentcc65567366c6e9d4989e3c8015c7b8f49b04203a (diff)
nick name more persistant than ever before
Diffstat (limited to '')
-rw-r--r--src/eu/siacs/conversations/persistance/DatabaseBackend.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/eu/siacs/conversations/persistance/DatabaseBackend.java b/src/eu/siacs/conversations/persistance/DatabaseBackend.java
index 81d4e4fb..434d6779 100644
--- a/src/eu/siacs/conversations/persistance/DatabaseBackend.java
+++ b/src/eu/siacs/conversations/persistance/DatabaseBackend.java
@@ -138,9 +138,9 @@ public class DatabaseBackend extends SQLiteOpenHelper {
public Conversation findConversation(Account account, String contactJid) {
SQLiteDatabase db = this.getReadableDatabase();
- String[] selectionArgs = { account.getUuid(), contactJid };
+ String[] selectionArgs = { account.getUuid(), contactJid+"%" };
Cursor cursor = db.query(Conversation.TABLENAME, null,
- Conversation.ACCOUNT + "=? AND " + Conversation.CONTACTJID + "=?",
+ Conversation.ACCOUNT + "=? AND " + Conversation.CONTACTJID + " like ?",
selectionArgs, null, null, null);
if (cursor.getCount() == 0)
return null;