From 2fcbaaefa57b35724864149ea7ed8a7509929f57 Mon Sep 17 00:00:00 2001 From: Jacco Flenter Date: Wed, 7 Jun 2017 18:40:12 +0200 Subject: [PATCH] fix test on node 7 (on travis) --- lib/server.js | 2 +- test/server.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/server.js b/lib/server.js index 212bb0efe..2c58dbcda 100644 --- a/lib/server.js +++ b/lib/server.js @@ -45,7 +45,7 @@ function Server (opts) { this.allowUpgrades = false !== opts.allowUpgrades; this.allowRequest = opts.allowRequest; this.cookie = false !== opts.cookie ? (opts.cookie || 'io') : false; - this.origins = opts.origins !== undefined ? opts.origins : '*'; + this.origins = opts.origins || '*'; this.cookiePath = false !== opts.cookiePath ? (opts.cookiePath || '/') : false; this.cookieHttpOnly = false !== opts.cookieHttpOnly; this.perMessageDeflate = false !== opts.perMessageDeflate ? (opts.perMessageDeflate || true) : false; diff --git a/test/server.js b/test/server.js index 393b97d8a..fd33f5c3a 100644 --- a/test/server.js +++ b/test/server.js @@ -917,7 +917,7 @@ describe('server', function () { it('should trigger transport close before open for ws', function (done) { var opts = { transports: ['websocket'] }; listen(opts, function (port) { - var url = 'ws://%s:%d'.s('0.0.0.50', port); + var url = 'ws://%s:%d'.s('0.0.0.0', port); var socket = new eioc.Socket(url); socket.on('open', function () { done(new Error('Test invalidation'));