datastore-core
Advanced tools
Comparing version 0.7.0 to 1.0.0
@@ -0,1 +1,11 @@ | ||
<a name="1.0.0"></a> | ||
# [1.0.0](https://github.com/ipfs/js-datastore-core/compare/v0.7.0...v1.0.0) (2020-04-06) | ||
### Bug Fixes | ||
* add buffer and cleanup ([#22](https://github.com/ipfs/js-datastore-core/issues/22)) ([f0f64a9](https://github.com/ipfs/js-datastore-core/commit/f0f64a9)) | ||
<a name="0.7.0"></a> | ||
@@ -2,0 +12,0 @@ # [0.7.0](https://github.com/ipfs/js-datastore-core/compare/v0.6.1...v0.7.0) (2019-05-29) |
{ | ||
"name": "datastore-core", | ||
"version": "0.7.0", | ||
"version": "1.0.0", | ||
"description": "Wrapper implmentation for interface-datastore", | ||
@@ -41,3 +41,3 @@ "leadMaintainer": "Pedro Teixeira <pedro@protocol.ai>", | ||
"devDependencies": { | ||
"aegir": "^19.0.3", | ||
"aegir": "^21.4.5", | ||
"async-iterator-all": "^1.0.0", | ||
@@ -48,4 +48,5 @@ "chai": "^4.2.0", | ||
"dependencies": { | ||
"buffer": "^5.5.0", | ||
"debug": "^4.1.1", | ||
"interface-datastore": "~0.7.0" | ||
"interface-datastore": "^0.8.2" | ||
}, | ||
@@ -58,12 +59,12 @@ "engines": { | ||
"David Dias <daviddias.p@gmail.com>", | ||
"achingbrain <alex@achingbrain.net>", | ||
"Friedel Ziegelmayer <dignifiedquire@gmail.com>", | ||
"Hugo Dias <hugomrdias@gmail.com>", | ||
"Jacob Heun <jacobheun@gmail.com>", | ||
"Zane Starr <zcstarr@zaner.attlocal.net>", | ||
"ᴠɪᴄᴛᴏʀ ʙᴊᴇʟᴋʜᴏʟᴍ <victorbjelkholm@gmail.com>", | ||
"Pedro Teixeira <i@pgte.me>", | ||
"Richard Schneider <makaretu@gmail.com>", | ||
"Vasco Santos <vasco.santos@moxy.studio>", | ||
"Victor Bjelkholm <victorbjelkholm@gmail.com>", | ||
"Zane Starr <zcstarr@zaner.attlocal.net>", | ||
"achingbrain <alex@achingbrain.net>" | ||
"Vasco Santos <vasco.santos@moxy.studio>" | ||
] | ||
} |
@@ -35,3 +35,3 @@ /* @flow */ | ||
_lookup (key) { | ||
for (let mount of this.mounts) { | ||
for (const mount of this.mounts) { | ||
if (mount.prefix.toString() === key.toString() || mount.prefix.isAncestorOf(key)) { | ||
@@ -160,11 +160,5 @@ const s = replaceStartWith(key.toString(), mount.prefix.toString()) | ||
return (async function * () { | ||
let completed = iterable.map(() => false) | ||
while (!completed.every(Boolean)) { | ||
for (const [idx, itr] of iterable.entries()) { | ||
const it = await itr.next() | ||
if (it.done) { | ||
completed[idx] = true | ||
continue | ||
} | ||
yield it.value | ||
for (let i = 0; i < iterable.length; i++) { | ||
for await (const v of iterable[i]) { | ||
yield v | ||
} | ||
@@ -171,0 +165,0 @@ } |
'use strict' | ||
const { Buffer } = require('buffer') | ||
const Key = require('interface-datastore').Key | ||
@@ -4,0 +5,0 @@ |
@@ -20,3 +20,3 @@ 'use strict' | ||
try { | ||
await (this.stores.map((store) => store.open())) | ||
await Promise.all(this.stores.map((store) => store.open())) | ||
} catch (err) { | ||
@@ -47,14 +47,10 @@ throw Errors.dbOpenFailedError() | ||
has (key) { | ||
return new Promise(async (resolve) => { | ||
await Promise.all(this.stores.map(async (store) => { | ||
const has = await store.has(key) | ||
async has (key) { | ||
for (const s of this.stores) { | ||
if (await s.has(key)) { | ||
return true | ||
} | ||
} | ||
if (has) { | ||
resolve(true) | ||
} | ||
})) | ||
resolve(false) | ||
}) | ||
return false | ||
} | ||
@@ -61,0 +57,0 @@ |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Unidentified License
License(Experimental) Something that seems like a license was found, but its contents could not be matched with a known license.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
17
0
553611
3
1
80
4628
+ Addedbuffer@^5.5.0
+ Addedabort-controller@3.0.0(transitive)
+ Addedat-least-node@1.0.0(transitive)
+ Addedbalanced-match@1.0.2(transitive)
+ Addedbase64-js@1.5.1(transitive)
+ Addedbrace-expansion@1.1.11(transitive)
+ Addedbuffer@5.7.16.0.3(transitive)
+ Addedconcat-map@0.0.1(transitive)
+ Addederr-code@2.0.3(transitive)
+ Addedevent-target-shim@5.0.1(transitive)
+ Addedfs-extra@8.1.09.1.0(transitive)
+ Addedget-iterator@1.0.2(transitive)
+ Addedgraceful-fs@4.2.11(transitive)
+ Addedieee754@1.2.1(transitive)
+ Addedinherits@2.0.4(transitive)
+ Addedinterface-datastore@0.8.3(transitive)
+ Addedipfs-utils@1.2.4(transitive)
+ Addedis-electron@2.2.2(transitive)
+ Addedis-plain-obj@2.1.0(transitive)
+ Addediso-random-stream@1.1.2(transitive)
+ Addediso-url@0.4.7(transitive)
+ Addedit-glob@0.0.7(transitive)
+ Addedjsonfile@4.0.06.1.0(transitive)
+ Addedmerge-options@2.0.0(transitive)
+ Addedminimatch@3.1.2(transitive)
+ Addednanoid@2.1.113.3.8(transitive)
+ Addednode-fetch@2.7.0(transitive)
+ Addedreadable-stream@3.6.2(transitive)
+ Addedsafe-buffer@5.2.1(transitive)
+ Addedstream-to-it@0.2.4(transitive)
+ Addedstring_decoder@1.3.0(transitive)
+ Addedtr46@0.0.3(transitive)
+ Addeduniversalify@0.1.22.0.1(transitive)
+ Addedutil-deprecate@1.0.2(transitive)
+ Addedwebidl-conversions@3.0.1(transitive)
+ Addedwhatwg-url@5.0.0(transitive)
- Removederr-code@1.1.2(transitive)
- Removedinterface-datastore@0.7.0(transitive)
- Removeduuid@3.4.0(transitive)
Updatedinterface-datastore@^0.8.2