diff --git a/packages/kbn-grouping/src/containers/query/types.ts b/packages/kbn-grouping/src/containers/query/types.ts index 69a284ecf7a5..c50e4f8b3391 100644 --- a/packages/kbn-grouping/src/containers/query/types.ts +++ b/packages/kbn-grouping/src/containers/query/types.ts @@ -7,7 +7,7 @@ */ import type { - InlineScript, + Script, MappingRuntimeField, MappingRuntimeFields, } from '@elastic/elasticsearch/lib/api/typesWithBodyKey'; @@ -52,7 +52,7 @@ export interface MainAggregation extends NamedAggregation { } export interface GroupingRuntimeField extends MappingRuntimeField { - script: InlineScript & { + script: Script & { params: Record; }; } diff --git a/x-pack/plugins/task_manager/server/task_store.test.ts b/x-pack/plugins/task_manager/server/task_store.test.ts index 9bc1a6414064..80c1f46f53e4 100644 --- a/x-pack/plugins/task_manager/server/task_store.test.ts +++ b/x-pack/plugins/task_manager/server/task_store.test.ts @@ -1406,7 +1406,7 @@ describe('TaskStore', () => { childEsClient.updateByQuery.mockResponse({ hits: { hits: [], total: 0, updated: 100, version_conflicts: 0 }, } as UpdateByQueryResponse); - await store.updateByQuery({ script: '' }, { max_docs: 10 }); + await store.updateByQuery({ script: { source: '' } }, { max_docs: 10 }); expect(childEsClient.updateByQuery).toHaveBeenCalledWith(expect.any(Object), { requestTimeout: 1000, });