mirror of
https://github.com/danog/telegram-tt.git
synced 2024-11-30 04:39:00 +01:00
Follow-up
This commit is contained in:
parent
fa6fd018cb
commit
8483f5f73d
@ -47,7 +47,7 @@ import {
|
||||
selectLocalAnimatedEmoji,
|
||||
} from '../../selectors';
|
||||
import {
|
||||
getMessageContent, isUserId, isMessageLocal, getMessageText, checkIfHasUnreadReactions, getMessageOriginalId,
|
||||
getMessageContent, isUserId, isMessageLocal, getMessageText, checkIfHasUnreadReactions,
|
||||
} from '../../helpers';
|
||||
import { onTickEnd } from '../../../util/schedulers';
|
||||
import { updateUnreadReactions } from '../../reducers/reactions';
|
||||
@ -665,7 +665,7 @@ function updateChatLastMessage(
|
||||
|
||||
if (currentLastMessage && !force) {
|
||||
const isSameOrNewer = (
|
||||
currentLastMessage.id === getMessageOriginalId(message)
|
||||
currentLastMessage.id === message.id || currentLastMessage.id === message.previousLocalId
|
||||
) || message.id > currentLastMessage.id;
|
||||
|
||||
if (!isSameOrNewer) {
|
||||
|
@ -311,7 +311,7 @@ export function selectFocusedMessageId(global: GlobalState, chatId: string) {
|
||||
export function selectIsMessageFocused(global: GlobalState, message: ApiMessage) {
|
||||
const focusedId = selectFocusedMessageId(global, message.chatId);
|
||||
|
||||
return focusedId ? focusedId === getMessageOriginalId(message) : false;
|
||||
return focusedId ? focusedId === message.id || focusedId === message.previousLocalId : false;
|
||||
}
|
||||
|
||||
export function selectIsMessageUnread(global: GlobalState, message: ApiMessage) {
|
||||
|
Loading…
Reference in New Issue
Block a user