From 5980e785db7b9897e0605e49fad423ecadd3471a Mon Sep 17 00:00:00 2001 From: rstular Date: Thu, 14 May 2020 12:16:08 +0200 Subject: Logging/debugging code --- js/messaging.js | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'js') diff --git a/js/messaging.js b/js/messaging.js index a5e5f6c..765f919 100644 --- a/js/messaging.js +++ b/js/messaging.js @@ -450,12 +450,15 @@ function setupEventListeners() { var randomencdivid = Math.floor(Math.random() * 9999).toString().padStart(4, "0"); var addrparts = window.location.href.split("/"); // engleski + var encrypted_message = sjcl.encrypt($("#msg-e2ee-pass-input").val(), msgcontent); + msgcontent = `
This message was encrypted by BežiApp. - ${sjcl.encrypt($("#msg-e2ee-pass-input").val(), msgcontent)} + ${encrypted_message}
` - } + } + + console.log(msgcontent); + console.log(encrypted_message); + sendMessage(value[$("#full-name").val()], msgsubject, htmlEncode(msgcontent)); $("#msg-body").val(""); $("#full-name").val(""); -- cgit v1.2.3