diff --git a/x-pack/plugins/observability_solution/infra/public/components/ml/anomaly_detection/flyout_home.tsx b/x-pack/plugins/observability_solution/infra/public/components/ml/anomaly_detection/flyout_home.tsx index 680c1c63cca43..958bd34a099b2 100644 --- a/x-pack/plugins/observability_solution/infra/public/components/ml/anomaly_detection/flyout_home.tsx +++ b/x-pack/plugins/observability_solution/infra/public/components/ml/anomaly_detection/flyout_home.tsx @@ -99,8 +99,9 @@ export const FlyoutHome = (props: Props) => { }); // Used for prefilling the feedback form (if both types are enabled do not prefill) + // In case the host type is the only option (if props.hideJobType is true) - prefill 'host' const mlJobTypeByNode = - hostJobSummaries.length > 0 && k8sJobSummaries.length === 0 + props.hideJobType || (hostJobSummaries.length > 0 && k8sJobSummaries.length === 0) ? 'host' : hostJobSummaries.length === 0 && k8sJobSummaries.length > 0 ? 'pod'