Skip to content
This repository has been archived by the owner. It is now read-only.
Permalink
Browse files
deps: Use shrinkwrap root for relative pathing
  • Loading branch information
iarna committed May 24, 2018
1 parent 2f0c883 commit 631d30a340f5805aed6e83f47a577ca4125599b2
Showing with 3 additions and 3 deletions.
  1. +3 −3 lib/install/deps.js
@@ -85,8 +85,8 @@ function doesChildVersionMatch (child, requested, requestor) {
}
}

function childDependencySpecifier (tree, name, spec) {
return npa.resolve(name, spec, packageRelativePath(tree))
function childDependencySpecifier (tree, name, spec, where) {
return npa.resolve(name, spec, where || packageRelativePath(tree))
}

exports.computeMetadata = computeMetadata
@@ -547,7 +547,7 @@ function addDependency (name, versionSpec, tree, log, done) {
try {
var req = childDependencySpecifier(tree, name, versionSpec)
if (tree.swRequires && tree.swRequires[name]) {
var swReq = childDependencySpecifier(tree, name, tree.swRequires[name])
var swReq = childDependencySpecifier(tree, name, tree.swRequires[name], tree.package._where)
}
} catch (err) {
return done(err)

0 comments on commit 631d30a

Please sign in to comment.