diff --git a/lib/application.js b/lib/application.js index 4ca66653..31c05a82 100644 --- a/lib/application.js +++ b/lib/application.js @@ -632,8 +632,7 @@ app.listen = function(cb) { } if (!self.get('url')) { - if (process.platform === 'win32' && listeningOnAll) { - // Windows browsers don't support `0.0.0.0` host in the URL + if (listeningOnAll) { // We are replacing it with localhost to build a URL // that can be copied and pasted into the browser. host = 'localhost'; diff --git a/test/app.test.js b/test/app.test.js index 6bd234bd..ec696bf4 100644 --- a/test/app.test.js +++ b/test/app.test.js @@ -839,8 +839,7 @@ describe('app', function() { app.set('host', undefined); app.listen(function() { - var host = process.platform === 'win32' ? 'localhost' : app.get('host'); - var expectedUrl = 'http://' + host + ':' + app.get('port') + '/'; + var expectedUrl = 'http://localhost:' + app.get('port') + '/'; expect(app.get('url'), 'url').to.equal(expectedUrl); done();