Socket
Socket
Sign inDemoInstall

@edjopato/datastore

Package Overview
Dependencies
12
Maintainers
1
Versions
14
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.3.1 to 0.3.2

9

dist/cache.js

@@ -54,8 +54,7 @@ "use strict";

}
if (keysToBeLoaded.length === 0) {
return {};
if (keysToBeLoaded.length > 0) {
const queryResults = await this._bulkQuery(keysToBeLoaded);
await Promise.all(Object.keys(queryResults)
.map(async (key) => this._store.set(key, queryResults[key], this._ttl)));
}
const queryResults = await this._bulkQuery(keysToBeLoaded);
await Promise.all(Object.keys(queryResults)
.map(async (key) => this._store.set(key, queryResults[key], this._ttl)));
const resultEntries = await Promise.all(keys

@@ -62,0 +61,0 @@ .map(async (key) => {

@@ -15,3 +15,2 @@ "use strict";

for (const [key, value] of map.entries()) {
console.log('cleanup old', key, value.until);
if (typeof value.until === 'number' && value.until < now) {

@@ -18,0 +17,0 @@ toBeDeleted.push(key);

{
"name": "@edjopato/datastore",
"version": "0.3.1",
"version": "0.3.2",
"description": "Handles different ways to store data within NodeJS",

@@ -5,0 +5,0 @@ "license": "MIT",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc