Allow one more retry if we get a 409
Handle cases where we get a 409 (missing/extra devices), handle it, then get a 410 (stale devices by registration id). // FREEBIE
This commit is contained in:
parent
8453424ebd
commit
1879e73c76
2 changed files with 2 additions and 2 deletions
|
@ -39831,7 +39831,7 @@ window.textsecure.messaging = function() {
|
|||
p.then(function() {
|
||||
var resetDevices = ((error.code == 410) ? error.response.staleDevices : error.response.missingDevices);
|
||||
getKeysForNumber(number, resetDevices)
|
||||
.then(reloadDevicesAndSend(number, false))
|
||||
.then(reloadDevicesAndSend(number, (error.code == 409)))
|
||||
.catch(function(error) {
|
||||
registerError(number, "Failed to reload device keys", error);
|
||||
});
|
||||
|
|
|
@ -152,7 +152,7 @@ window.textsecure.messaging = function() {
|
|||
p.then(function() {
|
||||
var resetDevices = ((error.code == 410) ? error.response.staleDevices : error.response.missingDevices);
|
||||
getKeysForNumber(number, resetDevices)
|
||||
.then(reloadDevicesAndSend(number, false))
|
||||
.then(reloadDevicesAndSend(number, (error.code == 409)))
|
||||
.catch(function(error) {
|
||||
registerError(number, "Failed to reload device keys", error);
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue