From b108027ba5578ba5905e28be6abf0dcac75a4422 Mon Sep 17 00:00:00 2001 From: Daniel Lugo Date: Wed, 29 Jan 2020 23:34:25 -0400 Subject: [PATCH] dont decrypt initial msg --- services/gunDB/contact-api/events/index.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/services/gunDB/contact-api/events/index.js b/services/gunDB/contact-api/events/index.js index 2d792616..cec931f4 100644 --- a/services/gunDB/contact-api/events/index.js +++ b/services/gunDB/contact-api/events/index.js @@ -406,7 +406,10 @@ const onOutgoing = cb => { typeof msg.timestamp === 'number' ) { newOuts[id].messages[mid] = { - body: await SEA.decrypt(msg.body, ourSec), + body: + msg.body === Actions.INITIAL_MSG + ? Actions.INITIAL_MSG + : await SEA.decrypt(msg.body, ourSec), timestamp: msg.timestamp } }