Last_message_seen_by in chat.

Database & APIs

In my app, I'm using a ready-made chat feature from Flutterflow, which talks to Firebase in the background. The chat creates documents in two collections: 'chats' and 'chat messages'. And I can't change how it works because it's all set up by Flutterflow. Chat document has a list called last_message_seen_by.
I use last_seen_by list to present new messages indicator to users.

Now, here's the behaviour: Let's say user A sends a message to user B, and user B's app is closed. User B will not appear on last_seen_by list until he opens the app and opens the exact chat where he received a new message. This is expected to behave like this.

BUT
When both users are using the app and one sends a message, suddenly both of them appear in last_message_ seen_by list, even if the other person wasn't looking at the chat at all.

How can I fix this? Can you help me out? I hope I explained it clearly enough for you ๐Ÿ™ƒ

What have you tried so far?

Checked documentation,
Looked into firebase.

Did you check FlutterFlow's Documentation for this topic?
Yes
1 reply