New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@vingle/memcache-plus

Package Overview
Dependencies
Maintainers
8
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@vingle/memcache-plus - npm Package Compare versions

Comparing version 0.3.2 to 0.3.3

45

lib/client.js

@@ -413,17 +413,3 @@ /**

// group keys by node index
const keysGroupedByNode = _.chain(keys)
.groupBy(key => this.getConnectionName({ command: "get", args: [key] }))
.map((keys, node) => ({ keys, node }))
.value();
return Promise.all(
keysGroupedByNode.map((group) => {
return this.run('get_multi', [group.keys, opts]);
})
).then(
(results) => {
return Object.assign({}, ...results)
}
).nodeify(cb);
return this.run('get_multi', [keys, opts]).nodeify(cb);
};

@@ -632,7 +618,28 @@

if (this.ready()) {
// First, retrieve the correct connection out of the hashring
var connection = this.getConnection({ command, args });
// For Multi Command
if (command === "get_multi") {
// group keys by node index
const [keys, opt] = args;
const keysGroupedByNode = _.chain(keys)
.groupBy(key => this.getConnectionName({ command: "get", args: [key] }))
.map((keys, node) => ({ keys, node }))
.value();
// Run this command
return connection[command].apply(connection, args).nodeify(cb);
return Promise.all(
keysGroupedByNode.map((group) => {
var connection = this.connections[group.node];
return connection.get_multi(group.keys, opt);
})
).then(
(results) => {
return Object.assign({}, ...results)
}
).nodeify(cb);
} else {
// First, retrieve the correct connection out of the hashring
var connection = this.getConnection({ command, args });
// Run this command
return connection[command].apply(connection, args).nodeify(cb);
}
} else if (this.bufferBeforeError === 0 || !this.queue) {

@@ -639,0 +646,0 @@ return Promise.reject(new Error('Connection is not ready, either not connected yet or disconnected')).nodeify(cb);

{
"name": "@vingle/memcache-plus",
"version": "0.3.2",
"version": "0.3.3",
"description": "Better memcache for node",

@@ -5,0 +5,0 @@ "main": "index.js",

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