From 9caf3bb01652e7cf725e2b40d16028acf95eaa29 Mon Sep 17 00:00:00 2001 From: Prateek Jain Date: Tue, 7 Jan 2020 23:01:37 +0530 Subject: [PATCH] [FIX] Go to direct message from members list (#1519) --- app/views/RoomMembersView/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/views/RoomMembersView/index.js b/app/views/RoomMembersView/index.js index 30be1624..40b59d29 100644 --- a/app/views/RoomMembersView/index.js +++ b/app/views/RoomMembersView/index.js @@ -119,7 +119,7 @@ class RoomMembersView extends React.Component { const db = database.active; const subsCollection = db.collections.get('subscriptions'); const query = await subsCollection.query(Q.where('name', item.username)).fetch(); - if (query) { + if (query.length) { const [room] = query; this.goRoom({ rid: room.rid, name: item.username, room }); } else {