Cleanup: Reactions, Delete for Everyone

This commit is contained in:
Scott Nonnenberg 2020-11-02 14:49:07 -08:00 committed by GitHub
parent e8759fc81b
commit 29eaa7b9a2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 29 additions and 27 deletions

View file

@ -610,16 +610,7 @@ export class ConversationController {
const messages = await getMessagesBySentAt(targetTimestamp, {
MessageCollection: window.Whisper.MessageCollection,
});
const targetMessage = messages.find(m => {
const contact = m.getContact();
if (!contact) {
return false;
}
const mcid = contact.get('id');
return mcid === targetFromId;
});
const targetMessage = messages.find(m => m.getContactId() === targetFromId);
if (targetMessage) {
return targetMessage.getConversation();