mirror of
https://github.com/grafana/grafana.git
synced 2025-01-26 16:27:02 -06:00
explore: fix null checks (#17191)
This commit is contained in:
parent
3b35e9d5e8
commit
5414a31101
@ -175,7 +175,7 @@ export default class Logs extends PureComponent<Props, State> {
|
||||
const hasLabel = hasData && dedupedData.hasUniqueLabels;
|
||||
const dedupCount = dedupedData.rows.reduce((sum, row) => sum + row.duplicates, 0);
|
||||
const showDuplicates = dedupStrategy !== LogsDedupStrategy.none && dedupCount > 0;
|
||||
const meta = [...data.meta];
|
||||
const meta = data.meta ? [...data.meta] : [];
|
||||
|
||||
if (dedupStrategy !== LogsDedupStrategy.none) {
|
||||
meta.push({
|
||||
@ -193,7 +193,9 @@ export default class Logs extends PureComponent<Props, State> {
|
||||
|
||||
// React profiler becomes unusable if we pass all rows to all rows and their labels, using getter instead
|
||||
const getRows = () => processedRows;
|
||||
const timeSeries = data.series.map(series => new TimeSeries(series));
|
||||
const timeSeries = data.series
|
||||
? data.series.map(series => new TimeSeries(series))
|
||||
: [new TimeSeries({ datapoints: [] })];
|
||||
const absRange = {
|
||||
from: range.from.valueOf(),
|
||||
to: range.to.valueOf(),
|
||||
|
Loading…
Reference in New Issue
Block a user