mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
Fixing invalidDate error if no timestamp provided
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>
This commit is contained in:
parent
b4e6aacb84
commit
8d9339d803
@ -116,7 +116,7 @@ export class LogList extends React.Component<Props> {
|
||||
|
||||
return this.props.logs
|
||||
.map(log => logStore.splitOutTimestamp(log))
|
||||
.map(([logTimestamp, log]) => (`${moment.tz(logTimestamp, UserStore.getInstance().localeTimezone).format()}${log}`));
|
||||
.map(([logTimestamp, log]) => (`${logTimestamp && moment.tz(logTimestamp, UserStore.getInstance().localeTimezone).format()}${log}`));
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@ -183,7 +183,7 @@ export class LogStore {
|
||||
const extraction = /^(\d+\S+)(.*)/m.exec(logs);
|
||||
|
||||
if (!extraction || extraction.length < 3) {
|
||||
return ["", ""];
|
||||
return ["", logs];
|
||||
}
|
||||
|
||||
return [extraction[1], extraction[2]];
|
||||
|
||||
Loading…
Reference in New Issue
Block a user