Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/npm/cli.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorisaacs <i@izs.me>2014-05-15 05:27:02 +0400
committerisaacs <i@izs.me>2014-05-15 05:27:02 +0400
commite4f26ef1959e59418f1e22ecd31a500ec92e7995 (patch)
tree7c7bb6356963de018f13c2d98b22c489353e4fe4
parentcb9c53321ae8b04e50e19bc251c42dbca6cc7e64 (diff)
addRemoteTarball: swap args to match addLocalTarball
-rw-r--r--lib/cache.js2
-rw-r--r--lib/cache/add-named.js2
-rw-r--r--lib/cache/add-remote-tarball.js2
3 files changed, 3 insertions, 3 deletions
diff --git a/lib/cache.js b/lib/cache.js
index da97b4a5f..4b9f3ff48 100644
--- a/lib/cache.js
+++ b/lib/cache.js
@@ -256,7 +256,7 @@ function add (args, cb) {
switch (p.protocol) {
case "http:":
case "https:":
- return addRemoteTarball(spec, null, { name: name }, cb)
+ return addRemoteTarball(spec, { name: name }, null, cb)
default:
if (isGitUrl(p)) return addRemoteGit(spec, p, false, cb)
diff --git a/lib/cache/add-named.js b/lib/cache/add-named.js
index 90b5a299e..7684d01d0 100644
--- a/lib/cache/add-named.js
+++ b/lib/cache/add-named.js
@@ -182,7 +182,7 @@ function addNameVersion (name, v, data, cb) {
if (!dist.shasum && !npm.config.get("force")) {
return cb(new Error("package lacks shasum: " + data._id))
}
- return addRemoteTarball(tb, dist.shasum, data, cb)
+ return addRemoteTarball(tb, data, dist.shasum, cb)
}
}
}
diff --git a/lib/cache/add-remote-tarball.js b/lib/cache/add-remote-tarball.js
index b14da7721..db9a05d82 100644
--- a/lib/cache/add-remote-tarball.js
+++ b/lib/cache/add-remote-tarball.js
@@ -15,7 +15,7 @@ var mkdir = require("mkdirp")
module.exports = addRemoteTarball
-function addRemoteTarball (u, shasum, pkgData, cb_) {
+function addRemoteTarball (u, pkgData, shasum, cb_) {
assert(typeof u === "string", "must have module URL")
assert(typeof cb_ === "function", "must have callback")