From 6a928e3377245b32c743e601b734db77b8cd387b Mon Sep 17 00:00:00 2001 From: lilia Date: Mon, 18 Apr 2016 15:45:04 -0700 Subject: [PATCH] Fix reference error in MessageReceiver from fe82e4 Fix a reference error when resolving a key conflict on an incoming end session message. See Signal-Android/5438. // FREEBIE --- js/libtextsecure.js | 2 +- libtextsecure/message_receiver.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/js/libtextsecure.js b/js/libtextsecure.js index 846f47f5..786d95de 100644 --- a/js/libtextsecure.js +++ b/js/libtextsecure.js @@ -37210,7 +37210,7 @@ MessageReceiver.prototype.extend({ if ((finalMessage.flags & textsecure.protobuf.DataMessage.Flags.END_SESSION) == textsecure.protobuf.DataMessage.Flags.END_SESSION && finalMessage.sync !== null) { - var number = textsecure.utils.unencodeNumber(encodedNumber)[0]; + var number = textsecure.utils.unencodeNumber(from)[0]; p = this.handleEndSession(number); } diff --git a/libtextsecure/message_receiver.js b/libtextsecure/message_receiver.js index 947fcd41..1957e711 100644 --- a/libtextsecure/message_receiver.js +++ b/libtextsecure/message_receiver.js @@ -311,7 +311,7 @@ MessageReceiver.prototype.extend({ if ((finalMessage.flags & textsecure.protobuf.DataMessage.Flags.END_SESSION) == textsecure.protobuf.DataMessage.Flags.END_SESSION && finalMessage.sync !== null) { - var number = textsecure.utils.unencodeNumber(encodedNumber)[0]; + var number = textsecure.utils.unencodeNumber(from)[0]; p = this.handleEndSession(number); }