axon-secure
Advanced tools
Comparing version 2.0.1 to 2.0.2
@@ -49,2 +49,3 @@ | ||
this.server = null; | ||
this.running = 0; | ||
this.socks = []; | ||
@@ -388,3 +389,12 @@ this.set('hwm', Infinity); | ||
debug('%s bind %s:%s', this.type, host, port); | ||
this.server.on('listening', this.emit.bind(this, 'bind')); | ||
this.server.on('listening', function () { | ||
this.running++; | ||
if (this.running > 1) { | ||
throw new Error('cannot bind() multiple times'); | ||
} | ||
this.emit('bind'); | ||
}.bind(this)); | ||
this.server.on('close', function () { | ||
this.running--; | ||
}.bind(this)); | ||
@@ -391,0 +401,0 @@ this.server.listen(port, host, fn); |
{ | ||
"name": "axon-secure", | ||
"description": "High-level messaging & socket patterns with optionional encryption implemented in pure js", | ||
"version": "2.0.1", | ||
"version": "2.0.2", | ||
"author": "Marcello Gesmundo <mgesmundo@yoovant.com>", | ||
@@ -6,0 +6,0 @@ "dependencies": { |
Sorry, the diff of this file is not supported yet
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
1141
40813
21