Socket
Socket
Sign inDemoInstall

fergies-inverted-index

Package Overview
Dependencies
Maintainers
1
Versions
68
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

fergies-inverted-index - npm Package Compare versions

Comparing version 13.0.0 to 13.1.0

5

package.json
{
"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",

6

src/main.js

@@ -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 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc