autobee 2.1.1 → 2.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/index.js +4 -3
  2. package/package.json +1 -1
package/index.js CHANGED
@@ -166,11 +166,11 @@ module.exports = class Autobee extends ReadyResource {
166
166
  }
167
167
 
168
168
  get isIndexer() {
169
- return this.writers.localWriter.isIndexer
169
+ return this.writers ? this.writers.localWriter.isIndexer : false
170
170
  }
171
171
 
172
172
  get writable() {
173
- return this.writers.writable
173
+ return this.writers ? this.writers.writable : false
174
174
  }
175
175
 
176
176
  // autobase compat
@@ -347,7 +347,8 @@ module.exports = class Autobee extends ReadyResource {
347
347
 
348
348
  openCore(key) {
349
349
  const encryption = this.encryptionKey ? new WriterEncryption(this) : null
350
- return this.store.get({ key, encryption })
350
+ const group = this.wakeupCapability ? this.wakeupCapability.discoveryKey : null
351
+ return this.store.get({ key, encryption, group })
351
352
  }
352
353
 
353
354
  _getEncryptionProvider(view) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "autobee",
3
- "version": "2.1.1",
3
+ "version": "2.1.2",
4
4
  "description": "Bee based autobase",
5
5
  "license": "Apache-2.0",
6
6
  "author": "Holepunch Inc.",