users() fix date time parsing

This commit is contained in:
Sebastian Hildebrandt 2026-01-06 08:37:28 +01:00
parent fe2035b61e
commit 493ee1f8c2

View File

@ -68,7 +68,8 @@ function parseUsersLinux(lines, phase) {
tty: l[1], tty: l[1],
date: timePos === 4 ? parseDate(l[2], l[3]) : l[2], date: timePos === 4 ? parseDate(l[2], l[3]) : l[2],
time: l[timePos], time: l[timePos],
ip: l && l.length > timePos + 1 ? l[timePos + 1].replace(/\(/g, '').replace(/\)/g, '') : '' ip: l && l.length > timePos + 1 ? l[timePos + 1].replace(/\(/g, '').replace(/\)/g, '') : '',
command: ''
}); });
} }
} else { } else {