fergies-inverted-index
Advanced tools
Comparing version 13.0.0 to 13.1.0
{ | ||
"name": "fergies-inverted-index", | ||
"version": "13.0.0", | ||
"version": "13.1.0", | ||
"description": "An inverted index that allows javascript objects to be easily serialised and retrieved using promises and map-reduce", | ||
@@ -10,2 +10,3 @@ "browser": "src/entrypoints/browser.js", | ||
"charwise": "3.0.1", | ||
"events": "^3.3.0", | ||
"traverse": "0.6.9" | ||
@@ -26,3 +27,3 @@ }, | ||
"path-browserify": "^1.0.1", | ||
"prettier": "^3.3.3", | ||
"prettier": "^2.8.8", | ||
"process": "^0.11.10", | ||
@@ -29,0 +30,0 @@ "standard": "17.1.0", |
@@ -0,1 +1,2 @@ | ||
import EventEmitter from 'events' | ||
import charwise from 'charwise' | ||
@@ -25,4 +26,6 @@ import read from './read.js' | ||
const events = new EventEmitter() | ||
const r = read(ops, tokenParser) | ||
const w = write(ops, tokenParser) | ||
const w = write(ops, tokenParser, events) | ||
@@ -41,2 +44,3 @@ // timestamp with time of creation (if not created already) | ||
this.DISTINCT = r.DISTINCT | ||
this.EVENTS = events | ||
this.EXIST = r.EXIST | ||
@@ -43,0 +47,0 @@ this.EXPORT = r.EXPORT |
import trav from 'traverse' | ||
import reader from './read.js' | ||
export default function (ops, tokenParser) { | ||
export default function (ops, tokenParser, events) { | ||
// TODO: set reset this to the max value every time the DB is restarted | ||
@@ -246,3 +246,6 @@ let incrementalId = 0 | ||
.catch(e => | ||
ops.db.put(['~CREATED'], timestamp()).then(TIMESTAMP_LAST_UPDATED) | ||
ops.db | ||
.put(['~CREATED'], timestamp()) | ||
.then(TIMESTAMP_LAST_UPDATED) | ||
.then(() => events.emit('ready')) | ||
) | ||
@@ -249,0 +252,0 @@ |
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
37479
787
4
+ Addedevents@^3.3.0
+ Addedevents@3.3.0(transitive)