mirror of
https://github.com/titanscouting/tra-analysis.git
synced 2025-09-06 23:17:22 +00:00
push all website files
This commit is contained in:
23
website/node_modules/npm/lib/utils/depr-check.js
generated
vendored
Normal file
23
website/node_modules/npm/lib/utils/depr-check.js
generated
vendored
Normal file
@@ -0,0 +1,23 @@
|
||||
'use strict'
|
||||
|
||||
const log = require('npmlog')
|
||||
|
||||
const deprecated = {}
|
||||
const deprWarned = {}
|
||||
|
||||
module.exports = deprCheck
|
||||
function deprCheck (data) {
|
||||
if (deprecated[data._id]) {
|
||||
data.deprecated = deprecated[data._id]
|
||||
}
|
||||
|
||||
if (data.deprecated) {
|
||||
deprecated[data._id] = data.deprecated
|
||||
if (!deprWarned[data._id]) {
|
||||
deprWarned[data._id] = true
|
||||
log.warn('deprecated', '%s: %s', data._id, data.deprecated)
|
||||
}
|
||||
}
|
||||
|
||||
return data
|
||||
}
|
Reference in New Issue
Block a user