Export a global.singletonFlairStore to allow cross-project singleton

This commit is contained in:
Luke Barnard 2017-10-19 12:00:03 +01:00
parent 71443e9b94
commit 25d14af616

View file

@ -147,8 +147,7 @@ class FlairStore extends EventEmitter {
} }
} }
let singletonFlairStore = null; if (global.singletonFlairStore === undefined) {
if (!singletonFlairStore) { global.singletonFlairStore = new FlairStore();
singletonFlairStore = new FlairStore();
} }
module.exports = singletonFlairStore; export default global.singletonFlairStore;