Fix string vs number comparison
Fix bug in device storage causing duplicate device messages after a 410.
This commit is contained in:
parent
a9549e2e0f
commit
061d57c95a
2 changed files with 2 additions and 2 deletions
|
@ -38131,7 +38131,7 @@ axolotlInternal.RecipientRecord = function() {
|
|||
// Add pending devices from tempKeys
|
||||
for (var encodedNumber in tempKeys) {
|
||||
var deviceNumber = textsecure.utils.unencodeNumber(encodedNumber)[0];
|
||||
var deviceId = textsecure.utils.unencodeNumber(encodedNumber)[1];
|
||||
var deviceId = parseInt(textsecure.utils.unencodeNumber(encodedNumber)[1]);
|
||||
if (deviceNumber === number && deviceIds.indexOf(deviceId) < 0) {
|
||||
deviceIds.push(deviceId);
|
||||
}
|
||||
|
|
|
@ -54,7 +54,7 @@
|
|||
// Add pending devices from tempKeys
|
||||
for (var encodedNumber in tempKeys) {
|
||||
var deviceNumber = textsecure.utils.unencodeNumber(encodedNumber)[0];
|
||||
var deviceId = textsecure.utils.unencodeNumber(encodedNumber)[1];
|
||||
var deviceId = parseInt(textsecure.utils.unencodeNumber(encodedNumber)[1]);
|
||||
if (deviceNumber === number && deviceIds.indexOf(deviceId) < 0) {
|
||||
deviceIds.push(deviceId);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue