const store = require("store");
store.set('foo', 'bar');
store.get('foo'); // 'bar'
store.get.call('foo'); // this._storage is not defined
There are number of ways to fix this and I'd be happy to try a PR if you're interested. Let me know if you have a preferred method (that = this, closure binding the internal vars, something else...) and I'll try to stick to that.
There are number of ways to fix this and I'd be happy to try a PR if you're interested. Let me know if you have a preferred method (that = this, closure binding the internal vars, something else...) and I'll try to stick to that.