Skip to content

Commit

Permalink
[ML] remove redundant type
Browse files Browse the repository at this point in the history
  • Loading branch information
darnautov committed Jul 21, 2021
1 parent 23e74e6 commit 8c3b9dd
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions x-pack/plugins/ml/server/lib/alerts/jobs_health_service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ import {
} from '../../routes/schemas/alerting_schema';
import { datafeedsProvider, DatafeedsService } from '../../models/job_service/datafeeds';
import { ALL_JOBS_SELECTION, HEALTH_CHECK_NAMES } from '../../../common/constants/alerts';
import { MlJobsResponse } from '../../../common/types/job_service';
import { DatafeedStats } from '../../../common/types/anomaly_detection_jobs';
import { GetGuards } from '../../shared_services/shared_services';
import { AnomalyDetectionJobsHealthAlertContext } from './register_jobs_monitoring_rule_type';
Expand Down Expand Up @@ -48,7 +47,7 @@ export function jobsHealthServiceProvider(

// Extract jobs from group ids and make sure provided jobs assigned to a current space
const jobsResponse = (
await mlClient.getJobs<MlJobsResponse>({
await mlClient.getJobs({
...(includeAllJobs ? {} : { job_id: jobAndGroupIds }),
})
).body.jobs;
Expand All @@ -61,7 +60,7 @@ export function jobsHealthServiceProvider(
...(excludeJobs?.groupIds ?? []),
];
const excludedJobsResponse = (
await mlClient.getJobs<MlJobsResponse>({
await mlClient.getJobs({
job_id: excludedJobAndGroupIds,
})
).body.jobs;
Expand Down

0 comments on commit 8c3b9dd

Please sign in to comment.