Don't require npm URLs to have a #commit-ish

Npm says it will default to `master`. That's OK by us.
This commit is contained in:
Tom Coleman
2015-11-25 13:08:07 +11:00
parent 222115665b
commit 81fff25ecb

View File

@@ -486,7 +486,7 @@ exports.isUrlWithSha = function (x) {
exports.isNpmUrl = function (x) {
// These are the various protocols that NPM supports, which we use to download NPM dependencies
// See https://docs.npmjs.com/files/package.json#git-urls-as-dependencies
return exports.isUrlWithSha(x) || /^(git|git\+ssh|git\+http|git\+https)?:\/\/.*#/.test(x);
return exports.isUrlWithSha(x) || /^(git|git\+ssh|git\+http|git\+https)?:\/\//.test(x);
};
exports.isPathRelative = function (x) {