replace double with triple equals

pull/20/head
sachaaaaa 7 years ago
parent 3481c0e58f
commit 666cb1d3cb

@ -837,7 +837,7 @@ MessageReceiver.prototype.extend({
}); });
}, },
async promptUserToAcceptFriendRequest(pubKey, message) { async promptUserToAcceptFriendRequest(pubKey, message) {
pubKey = pubKey.slice(0,30)+"..."; pubKey = pubKey.slice(0, 30) + "...";
let p = new Promise(resolve => { let p = new Promise(resolve => {
window.Whisper.events.trigger('showFriendRequest', { window.Whisper.events.trigger('showFriendRequest', {
pubKey, pubKey,
@ -855,12 +855,12 @@ MessageReceiver.prototype.extend({
async innerHandleContentMessage(envelope, plaintext) { async innerHandleContentMessage(envelope, plaintext) {
const content = textsecure.protobuf.Content.decode(plaintext); const content = textsecure.protobuf.Content.decode(plaintext);
if (envelope.type == textsecure.protobuf.Envelope.Type.FRIEND_REQUEST) { if (envelope.type === textsecure.protobuf.Envelope.Type.FRIEND_REQUEST) {
// only prompt friend request if there is no conversation yet // only prompt friend request if there is no conversation yet
let conversation; let conversation;
try { try {
conversation = ConversationController.get(envelope.source); conversation = ConversationController.get(envelope.source);
} catch(e) { } catch (e) {
} }
if (!conversation) { if (!conversation) {
const accepted = await this.promptUserToAcceptFriendRequest(envelope.source, content.dataMessage.body); const accepted = await this.promptUserToAcceptFriendRequest(envelope.source, content.dataMessage.body);
@ -1102,7 +1102,7 @@ MessageReceiver.prototype.extend({
async handlePreKeyBundleMessage(envelope, preKeyBundleMessage) { async handlePreKeyBundleMessage(envelope, preKeyBundleMessage) {
const { preKeyId, signedKeyId } = preKeyBundleMessage; const { preKeyId, signedKeyId } = preKeyBundleMessage;
const [ identityKey, preKey, signedKey, signature ] = [ const [identityKey, preKey, signedKey, signature] = [
preKeyBundleMessage.identityKey, preKeyBundleMessage.identityKey,
preKeyBundleMessage.preKey, preKeyBundleMessage.preKey,
preKeyBundleMessage.signedKey, preKeyBundleMessage.signedKey,

Loading…
Cancel
Save