From 1abf032418a00f296f9c4a74c0faea385300d553 Mon Sep 17 00:00:00 2001 From: Vincent Date: Mon, 4 May 2020 17:07:47 +1000 Subject: [PATCH] revert auto-execute --- libtextsecure/outgoing_message.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libtextsecure/outgoing_message.js b/libtextsecure/outgoing_message.js index 5ccb2adbc..eb2e5bf8f 100644 --- a/libtextsecure/outgoing_message.js +++ b/libtextsecure/outgoing_message.js @@ -478,7 +478,7 @@ OutgoingMessage.prototype = { // Send a message to a private group or a session chat (one to one) async sendSessionMessage(outgoingObjects) { // TODO: handle multiple devices/messages per transmit - const promiseFns = outgoingObjects.map(outgoingObject => async () => { + const promises = outgoingObjects.map(async outgoingObject => { if (!outgoingObject) { return; } @@ -512,7 +512,7 @@ OutgoingMessage.prototype = { } }); - await Promise.all(promiseFns.map(f => f())); + await Promise.all(promises); this.numbersCompleted += this.successfulNumbers.length; this.numberCompleted();