mirror of
https://github.com/titanscouting/tra-analysis.git
synced 2025-09-08 15:57:21 +00:00
push all website files
This commit is contained in:
15
website/node_modules/npm/lib/utils/package-id.js
generated
vendored
Normal file
15
website/node_modules/npm/lib/utils/package-id.js
generated
vendored
Normal file
@@ -0,0 +1,15 @@
|
||||
'use strict'
|
||||
var moduleName = require('./module-name.js')
|
||||
|
||||
module.exports = function (tree) {
|
||||
var pkg = tree.package || tree
|
||||
// FIXME: Excluding the '@' here is cleaning up after the mess that
|
||||
// read-package-json makes. =(
|
||||
if (pkg._id && pkg._id !== '@') return pkg._id
|
||||
var name = moduleName(tree)
|
||||
if (pkg.version) {
|
||||
return name + '@' + pkg.version
|
||||
} else {
|
||||
return name
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user