From d6a23061fc08224568418db74b3a3184bdc3d7f2 Mon Sep 17 00:00:00 2001 From: Nachtalb Date: Mon, 12 Apr 2021 23:22:58 +0200 Subject: [PATCH] Remove searchNicks for the time being We should not have search implementation without a specced filter / facet setup. --- src/plugins/messageStorage/sqlite.js | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/src/plugins/messageStorage/sqlite.js b/src/plugins/messageStorage/sqlite.js index dd6ebed1..cc8ccdf8 100644 --- a/src/plugins/messageStorage/sqlite.js +++ b/src/plugins/messageStorage/sqlite.js @@ -206,16 +206,9 @@ class MessageStorage { } let select = - 'SELECT msg, type, time, network, channel FROM messages WHERE type = "message" AND (json_extract(msg, "$.text") LIKE ?'; + 'SELECT msg, type, time, network, channel FROM messages WHERE type = "message" AND json_extract(msg, "$.text") LIKE ?'; const params = [`%${query.searchTerm}%`]; - if (query.searchNicks) { - select += ' OR json_extract(msg, "$.from.nick") LIKE ?)'; - params.push(query.searchTerm); - } else { - select += ")"; - } - if (query.networkUuid) { select += " AND network = ? "; params.push(query.networkUuid);