blob: 29a25c2fb7cce15308129e0cb532f1747da1a7e3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
var log = require('npmlog')
var ping = require('../ping.js')
function checkPing (cb) {
var tracker = log.newItem('checkPing', 1)
tracker.info('checkPing', 'Pinging registry')
ping({}, true, function (err, pong, data, res) {
if (err) { return cb(err) }
tracker.finish()
cb(null, [res.statusCode, res.statusMessage])
})
}
module.exports = checkPing
|