updated docs, improvement system

This commit is contained in:
Sebastian Hildebrandt
2016-08-19 11:27:36 +02:00
parent 7c40b5e519
commit 7a5382df3b
3 changed files with 11 additions and 3 deletions
+3 -2
View File
@@ -80,6 +80,7 @@
// --------------------------------
//
// version date comment
// 3.2.1 2016-08-20 updated docs, improvement system
// 3.2.0 2016-08-19 added battery info
// 3.1.1 2016-08-18 improved system and os detection (vm, ...), bugfix disksIO
// 3.1.0 2016-08-18 added docker stats
@@ -165,9 +166,9 @@ function system(callback) {
var lines = stdout.toString().split('\n');
lines.forEach(function (line) {
if (line.indexOf(':') != -1) {
if (line.toLowerCase().indexOf('manufacturer') != -1) result.manufacturer = line.split(':')[1].trim();
if (line.toLowerCase().indexOf('manufacturer') != -1) result.manufacturer = result.manufacturer || line.split(':')[1].trim();
if (line.toLowerCase().indexOf('product name') != -1) result.model = line.split(':')[1].trim();
if (line.toLowerCase().indexOf('version') != -1) result.version = line.split(':')[1].trim();
if (line.toLowerCase().indexOf('version') != -1) result.version = result.version || line.split(':')[1].trim();
if (line.toLowerCase().indexOf('serial number') != -1) result.serial = line.split(':')[1].trim();
if (line.toLowerCase().indexOf('uuid') != -1) result.uuid = line.split(':')[1].trim();
}