handle message while linking as if were already linked

pull/1528/head
Audric Ackermann 4 years ago
parent 781567f0df
commit 0a8335b125
No known key found for this signature in database
GPG Key ID: 999F434D76324AD4

@ -392,7 +392,7 @@ export async function innerHandleContentMessage(
'private' 'private'
); );
if (content.dataMessage && !UserUtils.isSignInByLinking()) { if (content.dataMessage) {
if ( if (
content.dataMessage.profileKey && content.dataMessage.profileKey &&
content.dataMessage.profileKey.length === 0 content.dataMessage.profileKey.length === 0
@ -403,16 +403,14 @@ export async function innerHandleContentMessage(
return; return;
} }
if (content.receiptMessage && !UserUtils.isSignInByLinking()) { if (content.receiptMessage) {
await handleReceiptMessage(envelope, content.receiptMessage); await handleReceiptMessage(envelope, content.receiptMessage);
return; return;
} }
if (content.typingMessage && !UserUtils.isSignInByLinking()) { if (content.typingMessage) {
await handleTypingMessage(envelope, content.typingMessage); await handleTypingMessage(envelope, content.typingMessage);
return; return;
} }
// Be sure to check for the UserUtils.isSignInByLinking() if you add another if here
if (content.configurationMessage) { if (content.configurationMessage) {
// this one can be quite long (downloads profilePictures and everything, is do not block) // this one can be quite long (downloads profilePictures and everything, is do not block)
void handleConfigurationMessage( void handleConfigurationMessage(
@ -421,7 +419,6 @@ export async function innerHandleContentMessage(
); );
return; return;
} }
// Be sure to check for the UserUtils.isSignInByLinking() if you add another if here
} catch (e) { } catch (e) {
window.log.warn(e); window.log.warn(e);
} }

Loading…
Cancel
Save