Closed masterofn1 closed 3 years ago
Hello @masterofn1 , The lastActiveAt field cannot be updated via the SDKs. The lastActiveAt field is set based on the user sessions being created and destroyed based on the connection to the CometChat Web-socket server.
Hope this helps. Thanks
Hello @masterofn1 , The lastActiveAt field cannot be updated via the SDKs. The lastActiveAt field is set based on the user sessions being created and destroyed based on the connection to the CometChat Web-socket server.
Hope this helps. Thanks
What will you recommend for us to capture the last active time of the user? it always pointed back to year 1970
@masterofn1 The lastActiveAt field will only be set for the users who have logged in at least once into CometChat. What I would suggest is that you check if the lastActiveAt field. If it is set to 0, it means that the user has not logged in to CometChat. If the lastActiveAt field is not 0, it means it shows the timestamp of the last time the user was connected to the CometChat web-socket servers.
Thanks
Describe the bug User's Last Active time is incorrect even after updating the user last Active time
To Reproduce Steps to reproduce the behavior:
Expected behavior
The submitted "lastActiveAt" of the certain user should be the latest one being passed on the sdk's method CometChat.updateUser
Actual behavior
The response of the method requests always give incorect time. In my case it was always in year 1970
Enviorment/Platfrom (please complete the following information):
Files (Optional)
build.gradle
(Project Level) implementation 'com.cometchat:pro-android-chat-sdk:2.1.0'Logs (Error Logs)