Skip to content

Commit

Permalink
Fix overriding bind address on CLI
Browse files Browse the repository at this point in the history
This fixes e.g. `node server 8080 0.0.0.0`.

Ref #2772.
  • Loading branch information
paulmelnikow committed Jan 15, 2019
1 parent a58de54 commit 8119360
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions server.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ const config = require('config').util.toObject()
if (+process.argv[2]) {
config.public.bind.port = +process.argv[2]
}
if (+process.argv[3]) {
config.public.bind.address = +process.argv[3]
if (process.argv[3]) {
config.public.bind.address = process.argv[3]
}

console.log('Configuration:')
Expand Down

0 comments on commit 8119360

Please sign in to comment.