Skip to content

Commit d2b8209

Browse files
authored
Fix dynamic_templates type (#3909)
1 parent 1ec9346 commit d2b8209

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

specification/_types/mapping/TypeMapping.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
* under the License.
1818
*/
1919

20-
import { Dictionary } from '@spec_utils/Dictionary'
20+
import { Dictionary, SingleKeyDictionary } from '@spec_utils/Dictionary'
2121
import { Metadata, PropertyName } from '@_types/common'
2222
import { DynamicMapping, DynamicTemplate } from './dynamic-template'
2323
import {
@@ -36,7 +36,7 @@ export class TypeMapping {
3636
date_detection?: boolean
3737
dynamic?: DynamicMapping
3838
dynamic_date_formats?: string[]
39-
dynamic_templates?: Dictionary<string, DynamicTemplate>[]
39+
dynamic_templates?: SingleKeyDictionary<string, DynamicTemplate>[]
4040
_field_names?: FieldNamesField
4141
index_field?: IndexField
4242
/** @doc_id mapping-meta-field */

specification/indices/put_mapping/IndicesPutMappingRequest.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
* under the License.
1818
*/
1919

20-
import { Dictionary } from '@spec_utils/Dictionary'
20+
import { Dictionary, SingleKeyDictionary } from '@spec_utils/Dictionary'
2121
import { RequestBase } from '@_types/Base'
2222
import {
2323
ExpandWildcards,
@@ -141,7 +141,7 @@ export interface Request extends RequestBase {
141141
/**
142142
* Specify dynamic templates for the mapping.
143143
*/
144-
dynamic_templates?: Dictionary<string, DynamicTemplate>[]
144+
dynamic_templates?: SingleKeyDictionary<string, DynamicTemplate>[]
145145
/**
146146
* Control whether field names are enabled for the index.
147147
*/

0 commit comments

Comments
 (0)