Allow reactions/replies after setting removalStage
This commit is contained in:
parent
b089eef942
commit
9eea26c5d6
4 changed files with 21 additions and 2 deletions
|
@ -781,7 +781,7 @@ export function CompositionArea({
|
||||||
// If no message request, but we haven't shared profile yet, we show profile-sharing UI
|
// If no message request, but we haven't shared profile yet, we show profile-sharing UI
|
||||||
if (
|
if (
|
||||||
!left &&
|
!left &&
|
||||||
((conversationType === 'direct' && removalStage !== 'justNotification') ||
|
(conversationType === 'direct' ||
|
||||||
(conversationType === 'group' && groupVersion === 1)) &&
|
(conversationType === 'group' && groupVersion === 1)) &&
|
||||||
isMissingMandatoryProfileSharing
|
isMissingMandatoryProfileSharing
|
||||||
) {
|
) {
|
||||||
|
|
|
@ -55,6 +55,21 @@ export async function enqueueReactionForSend({
|
||||||
);
|
);
|
||||||
|
|
||||||
const isMessageAStory = isStory(message.attributes);
|
const isMessageAStory = isStory(message.attributes);
|
||||||
|
|
||||||
|
if (
|
||||||
|
!isMessageAStory ||
|
||||||
|
isDirectConversation(messageConversation.attributes)
|
||||||
|
) {
|
||||||
|
log.info('Enabling profile sharing for reaction send');
|
||||||
|
if (!messageConversation.get('profileSharing')) {
|
||||||
|
messageConversation.set('profileSharing', true);
|
||||||
|
await window.Signal.Data.updateConversation(
|
||||||
|
messageConversation.attributes
|
||||||
|
);
|
||||||
|
}
|
||||||
|
await messageConversation.restoreContact();
|
||||||
|
}
|
||||||
|
|
||||||
const targetConversation =
|
const targetConversation =
|
||||||
isMessageAStory && isDirectConversation(messageConversation.attributes)
|
isMessageAStory && isDirectConversation(messageConversation.attributes)
|
||||||
? window.ConversationController.get(targetAuthorAci)
|
? window.ConversationController.get(targetAuthorAci)
|
||||||
|
|
|
@ -1049,6 +1049,7 @@ export function isMissingRequiredProfileSharing(
|
||||||
const doesConversationRequireIt =
|
const doesConversationRequireIt =
|
||||||
!conversation.isMe &&
|
!conversation.isMe &&
|
||||||
!conversation.left &&
|
!conversation.left &&
|
||||||
|
!conversation.removalStage &&
|
||||||
(isGroupV1(conversation) || isDirectConversation(conversation));
|
(isGroupV1(conversation) || isDirectConversation(conversation));
|
||||||
|
|
||||||
return Boolean(
|
return Boolean(
|
||||||
|
|
|
@ -1766,7 +1766,10 @@ function canReplyOrReact(
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!conversation.acceptedMessageRequest) {
|
if (
|
||||||
|
!conversation.acceptedMessageRequest &&
|
||||||
|
conversation.removalStage !== 'justNotification'
|
||||||
|
) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue