Comparing version 1.0.0 to 1.1.0
14
index.js
@@ -94,2 +94,4 @@ const cluster = require('cluster'); | ||
const _on = sockmq.on; | ||
sockmq.start = function start(options) { | ||
@@ -163,2 +165,14 @@ | ||
sockmq.on = function(eventName, fnc) { | ||
if (typeof eventName == 'object') { | ||
return eventName.forEach(function (e) { | ||
_on.apply(sockmq, [Object.keys(e)[0],e[Object.keys(e)[0]]]); | ||
}); | ||
} | ||
_on.apply(sockmq, [eventName, fnc]); | ||
}; | ||
module.exports = sockmq; |
{ | ||
"name": "sockmq", | ||
"version": "1.0.0", | ||
"version": "1.1.0", | ||
"description": "Socket based Message Queue for NodeJS", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
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
9239
7
210
2
3