From a8022077f6353ce011b016e4737639283d068836 Mon Sep 17 00:00:00 2001 From: Bruno Windels Date: Wed, 3 Nov 2021 02:20:11 +0100 Subject: [PATCH] add minimal logging --- src/matrix/Session.js | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/src/matrix/Session.js b/src/matrix/Session.js index 9ee458bd..04e2bd62 100644 --- a/src/matrix/Session.js +++ b/src/matrix/Session.js @@ -437,10 +437,13 @@ export class Session { // enable session backup, this requests the latest backup version if (!this._sessionBackup) { if (dehydratedDevice) { - const ssssKey = await createSSSSKeyFromDehydratedDeviceKey(dehydratedDevice.key, this._storage, this._platform); - if (ssssKey) { - this._writeSSSSKey(ssssKey); - } + await log.wrap("SSSSKeyFromDehydratedDeviceKey", async log => { + const ssssKey = await createSSSSKeyFromDehydratedDeviceKey(dehydratedDevice.key, this._storage, this._platform); + if (ssssKey) { + log.set("success", true); + this._writeSSSSKey(ssssKey); + } + }) } const txn = await this._storage.readTxn([ this._storage.storeNames.session,