simple-stats-server
Version:
dead-simple resource stats for Node.js servers
25 lines (21 loc) • 445 B
JavaScript
(function() {
var os;
os = require('os');
module.exports = {
system: function(cb) {
var time;
if (typeof cb !== 'function') {
cb = (function() {});
}
return cb(null, time = os.uptime());
},
process: function(cb) {
var time;
if (typeof cb !== 'function') {
cb = (function() {});
}
cb(null, time = process.uptime());
return time;
}
};
}).call(this);