cuckoo-filter
Advanced tools
Comparing version 1.1.2 to 1.1.3
{ | ||
"name": "cuckoo-filter", | ||
"version": "1.1.2", | ||
"version": "1.1.3", | ||
"description": "Cuckoo Filter: Better Than Bloom", | ||
@@ -17,3 +17,3 @@ "main": "src/index.js", | ||
"dependencies": { | ||
"cbor-js": "^0.1.0", | ||
"borc": "2.0.4", | ||
"fnv32": "0.0.1" | ||
@@ -20,0 +20,0 @@ }, |
'use strict' | ||
const cbor = require('cbor-js') | ||
const cbor = require('borc') | ||
const Bucket = require('./bucket') | ||
@@ -235,9 +235,9 @@ const Fingerprint = require('./fingerprint') | ||
} | ||
toCBOR(){ | ||
toCBOR () { | ||
return Buffer.from(cbor.encode(this.toJSON())) | ||
} | ||
static fromCBOR(buf){ | ||
let obj = cbor.decode(buf.buffer) | ||
static fromCBOR (buf) { | ||
let obj = cbor.decodeFirst(buf) | ||
return CuckooFilter.fromJSON(obj) | ||
} | ||
} |
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
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
21834
9
665
+ Addedborc@2.0.4
+ Addedbignumber.js@7.2.1(transitive)
+ Addedborc@2.0.4(transitive)
+ Addedcommander@2.20.3(transitive)
+ Addeddelimit-stream@0.1.0(transitive)
+ Addedieee754@1.2.1(transitive)
+ Addedjson-text-sequence@0.1.1(transitive)
- Removedcbor-js@^0.1.0
- Removedcbor-js@0.1.0(transitive)