diff --git a/x-pack/plugins/alerting/server/routes/rule_types.test.ts b/x-pack/plugins/alerting/server/routes/rule_types.test.ts index 0fa55d3ff048a..c52ce30e41dcd 100644 --- a/x-pack/plugins/alerting/server/routes/rule_types.test.ts +++ b/x-pack/plugins/alerting/server/routes/rule_types.test.ts @@ -65,7 +65,9 @@ describe('ruleTypesRoute', () => { validLegacyConsumers: [], } as RegistryAlertTypeWithAuth, ]; - const expectedResult: Array> = [ + const expectedResult: Array< + AsApiContract> + > = [ { id: '1', name: 'name', diff --git a/x-pack/plugins/alerting/server/routes/rule_types.ts b/x-pack/plugins/alerting/server/routes/rule_types.ts index 68c19f0e1434a..4521bdfd167a2 100644 --- a/x-pack/plugins/alerting/server/routes/rule_types.ts +++ b/x-pack/plugins/alerting/server/routes/rule_types.ts @@ -29,7 +29,7 @@ const rewriteBodyRes = (results: RegistryAlertTypeWithAuth[]) => { hasFieldsForAAD, validLegacyConsumers, ...rest - }) => ({ + }: RegistryAlertTypeWithAuth) => ({ ...rest, enabled_in_license: enabledInLicense, recovery_action_group: recoveryActionGroup,