FIX: do not attempt to mark as read a staged message (#21764)
This has not much impact as it would just be a silent 404 server side, but this is unnecessary work.
This commit is contained in:
parent
0bff95fcad
commit
4676524094
|
@ -462,7 +462,7 @@ export default class ChatLivePane extends Component {
|
||||||
const lastReadId =
|
const lastReadId =
|
||||||
this.args.channel.currentUserMembership?.lastReadMessageId;
|
this.args.channel.currentUserMembership?.lastReadMessageId;
|
||||||
let lastUnreadVisibleMessage = this.args.channel.visibleMessages.findLast(
|
let lastUnreadVisibleMessage = this.args.channel.visibleMessages.findLast(
|
||||||
(message) => !lastReadId || message.id > lastReadId
|
(message) => !message.staged && (!lastReadId || message.id > lastReadId)
|
||||||
);
|
);
|
||||||
|
|
||||||
// all intersecting messages are read
|
// all intersecting messages are read
|
||||||
|
|
Loading…
Reference in New Issue