diff options
Diffstat (limited to 'public/scripts/chat.js')
-rw-r--r-- | public/scripts/chat.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/public/scripts/chat.js b/public/scripts/chat.js index 13c7839..9a01a0e 100644 --- a/public/scripts/chat.js +++ b/public/scripts/chat.js @@ -156,7 +156,7 @@ function chat() { $('#messages').append(`<span style="color: green">${message}</span><br>`); } else { if (message.type === 'text') { - await encryption.storeMsg(connectedPeer.peer, message.data); + await encryption.storeMsg(connectedPeer.peer, message.data, passphrase); await encryption.decrypt(message.data, await encryption.get(connectedPeer.peer), await encryption.getPrivate(), passphrase) .then(plaintext => $('#messages').append(`${plaintext}<br>`)); } else if (message.type === 'key') { |