[Security Solution][Rules][Exceptions] - Fix wrong rule selection count in modal text (#155959)

## Summary

Addresses Kibana issue 155958
This commit is contained in:
Yara Tercero 2023-05-08 20:44:07 -07:00 committed by GitHub
parent e55a92eab0
commit e3e62182aa
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 3 deletions

View file

@ -148,7 +148,7 @@ export const bulkDuplicateRuleActions = {
DUPLICATE_EXCEPTIONS_INCLUDE_EXPIRED_EXCEPTIONS_LABEL: (rulesCount: number) => (
<FormattedMessage
id="xpack.securitySolution.detectionEngine.rules.allRules.bulkActions.duplicate.includeExpiredExceptionsCheckboxLabel"
defaultMessage="The {rulesCount, plural, one {rule} other {rules}} and all of {rulesCount, plural, one {its} other {their}} exceptions (active and expired)"
defaultMessage="The {rulesCount, plural, one {rule} other {rules}} and {rulesCount, plural, one {its} other {their}} exceptions"
values={{ rulesCount }}
/>
),
@ -179,7 +179,7 @@ export const bulkDuplicateRuleActions = {
'xpack.securitySolution.detectionEngine.rules.allRules.bulkActions.duplicate.exceptionsConfirmation.tooltip',
{
defaultMessage:
' If you choose to duplicate exceptions, the shared exceptions list will be duplicated by reference and the rule exceptions will be copied and created anew',
'Exception items associated with individual rules are duplicated. Exception items linked to shared exception lists are not. Instead, duplicated rules will reference the shared exception lists that contain the exception items.',
}
),
};

View file

@ -276,7 +276,7 @@ export const RulesTables = React.memo<RulesTableProps>(({ selectedTab }) => {
<BulkActionDuplicateExceptionsConfirmation
onCancel={cancelRuleDuplication}
onConfirm={confirmRuleDuplication}
rulesCount={numberOfSelectedRules}
rulesCount={numberOfSelectedRules > 0 ? numberOfSelectedRules : 1}
/>
)}
{isBulkEditFlyoutVisible && bulkEditActionType !== undefined && (