diff options
Diffstat (limited to 'lib/utils/depr-check.js')
-rw-r--r-- | lib/utils/depr-check.js | 22 |
1 files changed, 0 insertions, 22 deletions
diff --git a/lib/utils/depr-check.js b/lib/utils/depr-check.js deleted file mode 100644 index aa728a336..000000000 --- a/lib/utils/depr-check.js +++ /dev/null @@ -1,22 +0,0 @@ -'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 -} |