From fcf5ebe9da58c68bdd0758872e3d85a5cb573a3c Mon Sep 17 00:00:00 2001 From: Scott Nonnenberg Date: Fri, 10 Jul 2020 11:38:01 -0700 Subject: [PATCH] searchConversations: Search on e164 field, not id --- ts/sql/Server.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ts/sql/Server.ts b/ts/sql/Server.ts index e2a2190fac..7e7cbfa2b0 100644 --- a/ts/sql/Server.ts +++ b/ts/sql/Server.ts @@ -2252,14 +2252,14 @@ async function searchConversations( const rows = await db.all( `SELECT json FROM conversations WHERE ( - id LIKE $id OR + e164 LIKE $e164 OR name LIKE $name OR profileFullName LIKE $profileFullName ) ORDER BY active_at DESC LIMIT $limit`, { - $id: `%${query}%`, + $e164: `%${query}%`, $name: `%${query}%`, $profileFullName: `%${query}%`, $limit: limit || 100,