Skip to content

Commit

Permalink
hash the file name for electron store (#17)
Browse files Browse the repository at this point in the history
  • Loading branch information
vinnybod authored Apr 16, 2020
1 parent 2513df8 commit f3e50a2
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/store/electron-store.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,11 @@ export let namespacedElectronStore = null;

export default store;

/**
* create an electron store namespaced to the current url.
* The url is hashed since windows is more picky and doesn't allow :
* @param {string} url empire url
*/
export function initNamespacedStore(url) {
namespacedElectronStore = new Store({ name: url });
namespacedElectronStore = new Store({ name: btoa(url) });
}

0 comments on commit f3e50a2

Please sign in to comment.