Only validate replies on stories from self
This commit is contained in:
parent
a8ce959405
commit
5b6c624803
1 changed files with 9 additions and 2 deletions
|
@ -2552,7 +2552,11 @@ export class MessageModel extends window.Backbone.Model<MessageAttributesType> {
|
|||
storyQuote.get('sendStateByConversationId') || {};
|
||||
const sendState = sendStateByConversationId[sender.id];
|
||||
|
||||
if (!sendState) {
|
||||
const storyQuoteIsFromSelf =
|
||||
storyQuote.get('sourceUuid') ===
|
||||
window.storage.user.getCheckedUuid().toString();
|
||||
|
||||
if (storyQuoteIsFromSelf && !sendState) {
|
||||
log.warn(
|
||||
`${idLog}: Received storyContext message but sender was not in sendStateByConversationId. Dropping.`
|
||||
);
|
||||
|
@ -2561,7 +2565,10 @@ export class MessageModel extends window.Backbone.Model<MessageAttributesType> {
|
|||
return;
|
||||
}
|
||||
|
||||
if (sendState.isAllowedToReplyToStory === false) {
|
||||
if (
|
||||
storyQuoteIsFromSelf &&
|
||||
sendState.isAllowedToReplyToStory === false
|
||||
) {
|
||||
log.warn(
|
||||
`${idLog}: Received storyContext message but sender is not allowed to reply. Dropping.`
|
||||
);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue