Skip to content

Commit

Permalink
[APM] Average for transaction error rate includes null values (#74345) (
Browse files Browse the repository at this point in the history
#74358)

Co-authored-by: Cauê Marcondes <[email protected]>
  • Loading branch information
kibanamachine and cauemarcondes authored Aug 5, 2020
1 parent 87cfa3f commit 4b99054
Showing 1 changed file with 1 addition and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
import { EuiTitle } from '@elastic/eui';
import theme from '@elastic/eui/dist/eui_theme_light.json';
import { i18n } from '@kbn/i18n';
import { mean } from 'lodash';
import React, { useCallback } from 'react';
import { EuiPanel } from '@elastic/eui';
import { useChartsSync } from '../../../../hooks/useChartsSync';
Expand Down Expand Up @@ -79,7 +78,7 @@ export function ErroneousTransactionsRateChart() {
{
color: theme.euiColorVis7,
data: [],
legendValue: tickFormatY(mean(errorRates.map((rate) => rate.y))),
legendValue: tickFormatY(data?.average),
legendClickDisabled: true,
title: i18n.translate('xpack.apm.errorRateChart.avgLabel', {
defaultMessage: 'Avg.',
Expand Down

0 comments on commit 4b99054

Please sign in to comment.