Don't throw on unknown groups

// FREEBIE
This commit is contained in:
lilia 2015-10-02 12:53:45 -07:00
parent b42626923c
commit b0da491025
2 changed files with 6 additions and 2 deletions

View file

@ -39467,8 +39467,10 @@ MessageReceiver.prototype = {
promises.push(textsecure.storage.groups.getNumbers(decrypted.group.id).then(function(existingGroup) {
if (existingGroup === undefined) {
var members = decrypted.group.members;
if (decrypted.group.type != textsecure.protobuf.GroupContext.Type.UPDATE) {
throw new Error("Got message for unknown group");
members = [source];
console.log("Got message for unknown group");
}
return textsecure.storage.groups.createNewGroup(decrypted.group.members, decrypted.group.id);
} else {

View file

@ -290,8 +290,10 @@ MessageReceiver.prototype = {
promises.push(textsecure.storage.groups.getNumbers(decrypted.group.id).then(function(existingGroup) {
if (existingGroup === undefined) {
var members = decrypted.group.members;
if (decrypted.group.type != textsecure.protobuf.GroupContext.Type.UPDATE) {
throw new Error("Got message for unknown group");
members = [source];
console.log("Got message for unknown group");
}
return textsecure.storage.groups.createNewGroup(decrypted.group.members, decrypted.group.id);
} else {