aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--public/scripts/2_encryption.js7
-rw-r--r--public/scripts/chat.js2
2 files changed, 8 insertions, 1 deletions
diff --git a/public/scripts/2_encryption.js b/public/scripts/2_encryption.js
index 05b4b69..4d05780 100644
--- a/public/scripts/2_encryption.js
+++ b/public/scripts/2_encryption.js
@@ -85,4 +85,9 @@ function testEncryption() {
})
}
-testEncryption();
+// TODO: Export as module or sth
+// REMEMBER: UGLY EXPORT!
+window.generateKeys = generateKeys;
+window.encrypt = encrypt;
+window.decrypt = decrypt;
+window.testEncryption = testEncryption;
diff --git a/public/scripts/chat.js b/public/scripts/chat.js
index b2f2816..b33d503 100644
--- a/public/scripts/chat.js
+++ b/public/scripts/chat.js
@@ -66,3 +66,5 @@ $(document).ready(() => {
$('[toggle-contact-modal]').on('click', () => $('#add_contact_modal').toggleClass('is-active'))
});
+
+testEncryption();