Skip to content

Commit 08b693d

Browse files
[APM] Average for transaction error rate includes null values (#74345) (#74359)
Co-authored-by: Cauê Marcondes <55978943+cauemarcondes@users.noreply.github.com>
1 parent c724824 commit 08b693d

File tree

1 file changed

+1
-2
lines changed
  • x-pack/plugins/apm/public/components/shared/charts/ErroneousTransactionsRateChart

1 file changed

+1
-2
lines changed

x-pack/plugins/apm/public/components/shared/charts/ErroneousTransactionsRateChart/index.tsx

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66
import { EuiTitle } from '@elastic/eui';
77
import theme from '@elastic/eui/dist/eui_theme_light.json';
88
import { i18n } from '@kbn/i18n';
9-
import { mean } from 'lodash';
109
import React, { useCallback } from 'react';
1110
import { EuiPanel } from '@elastic/eui';
1211
import { useChartsSync } from '../../../../hooks/useChartsSync';
@@ -79,7 +78,7 @@ export const ErroneousTransactionsRateChart = () => {
7978
{
8079
color: theme.euiColorVis7,
8180
data: [],
82-
legendValue: tickFormatY(mean(errorRates.map((rate) => rate.y))),
81+
legendValue: tickFormatY(data?.average),
8382
legendClickDisabled: true,
8483
title: i18n.translate('xpack.apm.errorRateChart.avgLabel', {
8584
defaultMessage: 'Avg.',

0 commit comments

Comments
 (0)