From b2d5df9533e62a338057cb3e576078fd524bb163 Mon Sep 17 00:00:00 2001 From: DwCay Date: Wed, 3 Aug 2022 12:02:44 +0300 Subject: [PATCH] changed methods for encrypt --- src/store/store.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/store/store.js b/src/store/store.js index f81d7b5..6b7b460 100644 --- a/src/store/store.js +++ b/src/store/store.js @@ -55,7 +55,7 @@ class Store { fetchWrapper.postAuth('data/private', { networkIdentifier: this.nodeInfo.networkIdentifier, lastBlockID: this.nodeInfo.lastBlockID - }, [...this.encryptUserData(data)]) + }, [...this.encryptAccountData(data)]) .then(() => this.fetchNewAccountData()) } @@ -180,7 +180,7 @@ class Store { })) } - encryptUserData(data) { + encryptAccountData(data) { return data.map((item) => { let value = cryptography.encryptMessageWithPassphrase(cryptography.getRandomBytes(32).toString('hex') + ":" + item.value, this.passPhrase, this.pubKey); return {