mirror of
https://github.com/orbitdb/orbitdb.git
synced 2025-10-07 22:57:07 +00:00
Fix options
This commit is contained in:
@@ -44,10 +44,9 @@ class OrbitDB {
|
||||
|
||||
_createStore(Store, dbname, options) {
|
||||
if(!options) options = {};
|
||||
if(options.subscribe === undefined) Object.assign(options, { subscribe: true });
|
||||
|
||||
const replicate = options.subscribe ? options.subscribe : true;
|
||||
const store = new Store(this._ipfs, this.user.username, dbname, options);
|
||||
return this._subscribe(store, dbname, options.subscribe)
|
||||
return this._subscribe(store, dbname, replicate)
|
||||
.then(() => this.stores[dbname] = store)
|
||||
.then(() => store);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user