Skip to content

Commit

Permalink
fix: Project without any 'now.json' are failing
Browse files Browse the repository at this point in the history
  • Loading branch information
nicolasdao committed Dec 20, 2017
1 parent fb3885e commit 1f6354b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/webfunc.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,11 +41,11 @@ const getActiveEnv = memoize => {
const processWebFunc = getProcessEnv().NODE_ENV
const activeEnv = ((appconfig || {}).env || {}).active || processWebFunc || 'default'
if (activeEnv) {
const env = Object.assign((appconfig.env[activeEnv] || {}), { _name: activeEnv })
const env = Object.assign((((appconfig || {}).env || {})[activeEnv] || {}), { _name: activeEnv })
return env
}
else
return null
return {}
}

let headersCollection = null
Expand Down

0 comments on commit 1f6354b

Please sign in to comment.