/ SDKs / Android
SDKs
Chat SDKs Android v4
Chat SDKs Android
Chat SDKs
Android
Version 4

When a user is online, all data associated with the group channels they are a member of are automatically updated. However, when a user is disconnected from the Sendbird server and reconnects later, the refresh() method should be called to update the channels with the latest information.

KotlinKTX
groupChannel.refresh { e ->
    if (e != null) {
        // Handle error.
    }

    // ...
}

Note: If you want to provide the updated channels with the latest information when your user's app is in the foreground, call refresh() in the onReconnectSucceeded() method which receives a callback from the Sendbird server when successfully reconnected.