cometchat / chat-sdk-react-native

Voice & Video Calling and Text Chat SDK for React Native
Other
18 stars 17 forks source link

Background/Foreground user presence #13

Closed shiroganee closed 4 years ago

shiroganee commented 4 years ago

Describe the problem

User Presence - Offline/Online appears only when we turn off application/turn on. In case of iOS it is rather hard to rely on as you often just put the app in background

What was the expected behavior?

It should act on background / foreground also.

Reproduction

use two devices and register on one of them user presence listener, on 2nd one put app in background and see that nothing happens

Environment

newest ios and newest library version

mayur-bhandari commented 4 years ago

Hello @shiroganee ,

This is the default behavior. When you put the app in the background state the app is still connected to our WS server. When you kill the app, it will disconnect from the WS server and the user status will be changed to offline.

Warm Regards,

CometChat Pro Mayur Bhandari

mayur-bhandari commented 4 years ago

Closing due to inactivity.