Comparing version 0.6.6 to 0.7.1
{ | ||
"name": "uuws", | ||
"version": "0.6.6", | ||
"version": "0.7.1", | ||
"scripts": { | ||
@@ -5,0 +5,0 @@ "install": "node-gyp rebuild > build_log.txt 2>&1 || exit 0" |
18
uws.js
@@ -127,7 +127,10 @@ 'use strict'; | ||
this.onmessage = noop; | ||
} else if (!eventName || eventName === 'close') { | ||
} | ||
if (!eventName || eventName === 'close') { | ||
this.onclose = noop; | ||
} else if (!eventName || eventName === 'ping') { | ||
} | ||
if (!eventName || eventName === 'ping') { | ||
this.onping = noop; | ||
} else if (!eventName || eventName === 'pong') { | ||
} | ||
if (!eventName || eventName === 'pong') { | ||
this.onpong = noop; | ||
@@ -148,10 +151,7 @@ } | ||
this.onmessage = noop; | ||
} | ||
if (eventName === 'close' && this.onclose === cb) { | ||
} else if (eventName === 'close' && this.onclose === cb) { | ||
this.onclose = noop; | ||
} | ||
if (eventName === 'ping' && this.onping === cb) { | ||
} else if (eventName === 'ping' && this.onping === cb) { | ||
this.onping = noop; | ||
} | ||
if (eventName === 'pong' && this.onpong === cb) { | ||
} else if (eventName === 'pong' && this.onpong === cb) { | ||
this.onpong = noop; | ||
@@ -158,0 +158,0 @@ } |