1
0
Fork 0
mirror of https://github.com/terribleplan/next.js.git synced 2024-01-19 02:48:18 +00:00

Fall back to showing localhost when no hostname is provided

This commit is contained in:
Tim Neutkens 2019-01-18 12:15:15 +01:00
parent 8065130343
commit 5ba7dba951

View file

@ -44,7 +44,7 @@ const port = args['--port'] || 3000
startServer({dir}, port, args['--hostname'])
.then(async (app) => {
// tslint:disable-next-line
console.log(`> Ready on http://${args['--hostname']}:${port}`)
console.log(`> Ready on http://${args['--hostname'] || 'localhost'}:${port}`)
await app.prepare()
})
.catch((err) => {