markStoryRead: More logging in unusual cases
This commit is contained in:
parent
b65890b07d
commit
44db76531e
8 changed files with 47 additions and 9 deletions
|
@ -35,6 +35,7 @@ import { getUserConversationId } from './user';
|
|||
import { getDistributionListSelector } from './storyDistributionLists';
|
||||
import { getStoriesEnabled } from './items';
|
||||
import { calculateExpirationTimestamp } from '../../util/expirationTimer';
|
||||
import { getMessageIdForLogging } from '../../util/idForLogging';
|
||||
|
||||
export const getStoriesState = (state: StateType): StoriesStateType =>
|
||||
state.stories;
|
||||
|
@ -191,12 +192,18 @@ export function getStoryView(
|
|||
views = innerViews;
|
||||
}
|
||||
|
||||
const messageIdForLogging = getMessageIdForLogging({
|
||||
...pick(story, 'type', 'sourceUuid', 'sourceDevice'),
|
||||
sent_at: story.timestamp,
|
||||
});
|
||||
|
||||
return {
|
||||
attachment,
|
||||
canReply: canReply(story, ourConversationId, conversationSelector),
|
||||
isHidden: Boolean(sender.hideStory),
|
||||
isUnread: story.readStatus === ReadStatus.Unread,
|
||||
messageId: story.messageId,
|
||||
messageIdForLogging,
|
||||
readAt,
|
||||
sender,
|
||||
sendState,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue