From 3b43153e92e6643247f326e9fd2baa7eab2cd34f Mon Sep 17 00:00:00 2001 From: Adhiraj Singh Date: Wed, 1 Jun 2022 19:13:12 +0530 Subject: [PATCH] fix: send unavailable if markOnlineOnConnect=false --- src/Socket/chats.ts | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/Socket/chats.ts b/src/Socket/chats.ts index 21319c5..8963117 100644 --- a/src/Socket/chats.ts +++ b/src/Socket/chats.ts @@ -612,9 +612,7 @@ export const makeChatsSocket = (config: SocketConfig) => { fetchProps(), fetchBlocklist(), fetchPrivacySettings(), - markOnlineOnConnect - ? sendPresenceUpdate('available') - : undefined + sendPresenceUpdate(markOnlineOnConnect ? 'available' : 'unavailable') ]) }