From 9feed0c767da33ab4d98f806c1e3aea4f14341af Mon Sep 17 00:00:00 2001 From: Tony Kovanen Date: Sun, 17 Jul 2016 01:49:26 +0300 Subject: [PATCH] Look up `forward-npm` from now nowProperties --- lib/index.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/index.js b/lib/index.js index 873101f..06cf1dd 100644 --- a/lib/index.js +++ b/lib/index.js @@ -63,9 +63,11 @@ export default class Now extends EventEmitter { throw e; } + const nowProperties = pkg.now || {}; + // Read .npmrc let npmrc = {}; - if (pkg['forward-npm']) { + if (nowProperties['forward-npm']) { try { npmrc = await readFile(resolvePath(path, '.npmrc'), 'utf8'); npmrc = parseIni(npmrc); @@ -95,7 +97,6 @@ export default class Now extends EventEmitter { this._files = hashes; - const nowProperties = pkg.now || {}; const engines = nowProperties.engines || pkg.engines; const deployment = await this.retry(async (bail) => {