From 65f0c6823d81fdbf68d3cd3dc8260b62868c40d9 Mon Sep 17 00:00:00 2001 From: "Alex A. Naanou" Date: Sat, 15 Oct 2022 13:42:51 +0300 Subject: [PATCH] bugfix... Signed-off-by: Alex A. Naanou --- browser.js | 5 +++-- pwiki/store/base.js | 1 + 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/browser.js b/browser.js index 4ea60be..055cbf0 100755 --- a/browser.js +++ b/browser.js @@ -62,8 +62,9 @@ Promise.all([ // persistent stores... // - store.update('/Stores/localStorage', { + store.update('Stores/localStorage', { __proto__: localstoragestore.localStorageStore, + __prefix__: '--pwiki-nested:', data: localStorage, }), store.update('Stores/sessionStorage', { @@ -76,7 +77,7 @@ Promise.all([ store.update('Stores/IndexedDB', { __proto__: indexeddb.IndexedDBStore, }), - store.update('Stores/memory', { + store.update('/Stores/memory', { __proto__: basestore.MetaStore, data: { '': {text: 'memory store'}, diff --git a/pwiki/store/base.js b/pwiki/store/base.js index a1296eb..1c64a59 100755 --- a/pwiki/store/base.js +++ b/pwiki/store/base.js @@ -742,6 +742,7 @@ module.MetaStore = { : data // add substore... if(object.childOf(data, BaseStore)){ + path = pwpath.sanitize(path, 'string') ;(this.substores = this.substores ?? {})[path] = data return this } // add to substore...