onReceiveC2CMessageReadReceipts method
Implementation
void onReceiveC2CMessageReadReceipts(List<V2TimMessageReceipt> receiptList) {
try {
for (var receipt in receiptList) {
final userID = receipt.userID;
final messageList = _messageListMap[userID];
final isNotEmpty = messageList?.isNotEmpty ?? false;
if (isNotEmpty) {
for (V2TimMessage element in messageList!) {
final isSelf = element.isSelf ?? true;
final isPeerRead = element.isPeerRead ?? false;
if (isSelf && !isPeerRead) {
element.isPeerRead = true;
}
}
updateMessageList(messageList: messageList, userID: userID);
}
}
} catch (_) {}
}