diff --git a/src/index.js b/src/index.js index 1ffbc055..d362ba8c 100644 --- a/src/index.js +++ b/src/index.js @@ -106,14 +106,7 @@ class IpfsRepo { }, (cb) => { log('creating keystore') - const keysBaseStore = backends.create('keys', path.join(this.path, 'keys'), this.options) - blockstore( - keysBaseStore, - this.options.storageBackendOptions.keys, - cb) - }, - (keys, cb) => { - this.keys = keys + this.keys = backends.create('keys', path.join(this.path, 'keys'), this.options) cb() }, diff --git a/test/keystore-test.js b/test/keystore-test.js index a04e1695..0c3469c6 100644 --- a/test/keystore-test.js +++ b/test/keystore-test.js @@ -11,5 +11,10 @@ module.exports = (repo) => { it('exists', () => { expect(repo).to.have.property('keys') }) + it('implements interface-datastore', () => { + const keys = repo.keys + expect(keys.batch).to.exist() + expect(keys.query).to.exist() + }) }) }