Skip to content

Commit

Permalink
Fix config format
Browse files Browse the repository at this point in the history
  • Loading branch information
zackbloom committed Nov 12, 2013
1 parent a27dbaf commit 0c28bf9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions server.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ parser = (req, res, next) ->
loadApp = (logger, loadedConfig) ->
app = express()

APP_ROOT = process.env.APP_ROOT ? loadedConfig.server?.appRoot ? ''
APP_ROOT = process.env.APP_ROOT ? loadedConfig.get('server.appRoot').get() ? ''

moduleGroups = {}
loadModuleGroup = (group) ->
Expand Down Expand Up @@ -107,7 +107,7 @@ loadApp = (logger, loadedConfig) ->
app.get "#{ APP_ROOT }/v1/health-check", (req, res) ->
res.send('OK\n')

port = process.env.PORT ? loadedConfig.server?.port ? 5000
port = process.env.PORT ? loadedConfig.get('server.port').get() ? 5000
app.listen(port)

logger.log('Server listening on port %d in %s mode', port, app.settings.env)
Expand Down

0 comments on commit 0c28bf9

Please sign in to comment.