Fix group send (fixes #129)

This commit is contained in:
Matt Corallo 2015-01-15 19:58:18 -10:00
parent 94e14f2c85
commit c112c59ce6
3 changed files with 11 additions and 4 deletions

View file

@ -8183,8 +8183,7 @@ window.textsecure.messaging = function() {
});
}
for (var i in numbers) {
var number = numbers[i];
var getDevicesAndSendToNumber = function(number) {
var devicesForNumber = textsecure.storage.devices.getDeviceObjectsForNumber(number);
var promises = [];
@ -8205,6 +8204,9 @@ window.textsecure.messaging = function() {
doSendMessage(number, devicesForNumber, true);
});
}
for (var i in numbers)
getDevicesAndSendToNumber(numbers[i]);
}
makeAttachmentPointer = function(attachment) {

View file

@ -203,8 +203,7 @@ window.textsecure.messaging = function() {
});
}
for (var i in numbers) {
var number = numbers[i];
var getDevicesAndSendToNumber = function(number) {
var devicesForNumber = textsecure.storage.devices.getDeviceObjectsForNumber(number);
var promises = [];
@ -225,6 +224,9 @@ window.textsecure.messaging = function() {
doSendMessage(number, devicesForNumber, true);
});
}
for (var i in numbers)
getDevicesAndSendToNumber(numbers[i]);
}
makeAttachmentPointer = function(attachment) {

View file

@ -464,5 +464,8 @@ axolotlTestVectors = function() {
tests[tests.length] = {name: "No-PreKey fake end-session test as Bob", vectors: axolotlNoPreKeyEndSessionTestVectorsBob};
*/
//TODO: GROUPS
return tests;
}();