Skip to content

Commit

Permalink
remove unused import
Browse files Browse the repository at this point in the history
  • Loading branch information
CAWilson94 committed Nov 6, 2024
1 parent 5e76d2b commit a9f10e5
Showing 1 changed file with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
import React, { memo } from 'react';
import { ALERT_RISK_SCORE } from '@kbn/rule-data-utils';
import { FormattedMessage } from '@kbn/i18n-react';
import { formatRiskScore } from '../../../../entity_analytics/common';
import { AlertHeaderBlock } from './alert_header_block';
import { RISK_SCORE_TITLE_TEST_ID, RISK_SCORE_VALUE_TEST_ID } from './test_ids';
import { useDocumentDetailsContext } from '../../shared/context';
Expand All @@ -26,9 +25,9 @@ export const RiskScore = memo(() => {

let alertRiskScore: string;
if (typeof fieldsData === 'string') {
alertRiskScore = formatRiskScore(Number(fieldsData));
alertRiskScore = fieldsData;
} else if (Array.isArray(fieldsData) && fieldsData.length > 0) {
alertRiskScore = formatRiskScore(Number(fieldsData[0]));
alertRiskScore = fieldsData[0];
} else {
return null;
}
Expand Down

0 comments on commit a9f10e5

Please sign in to comment.