mirror of
https://github.com/kremalicious/umami.git
synced 2024-11-15 17:55:08 +01:00
fix: 🩹 null value check for metric data
This commit is contained in:
parent
586529a5ca
commit
c8ebb7695c
@ -59,7 +59,10 @@ export function MetricsTable({
|
|||||||
|
|
||||||
const filteredData = useMemo(() => {
|
const filteredData = useMemo(() => {
|
||||||
if (data) {
|
if (data) {
|
||||||
let items = percentFilter(dataFilter ? dataFilter(data, filterOptions) : data);
|
const dataWithoutNullValues = data.filter(val => val.x !== null);
|
||||||
|
let items = percentFilter(
|
||||||
|
dataFilter ? dataFilter(dataWithoutNullValues, filterOptions) : dataWithoutNullValues,
|
||||||
|
);
|
||||||
if (limit) {
|
if (limit) {
|
||||||
items = items.filter((e, i) => i < limit);
|
items = items.filter((e, i) => i < limit);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user