File tree 2 files changed +11
-7
lines changed
packages/core/src/getters
2 files changed +11
-7
lines changed Original file line number Diff line number Diff line change @@ -178,18 +178,17 @@ export const combineSchemas = ({
178
178
return {
179
179
value : `typeof ${ pascal ( name ) } [keyof typeof ${ pascal ( name ) } ] ${ nullable } ` ,
180
180
imports : [
181
- ...resolvedData . imports . map < GeneratorImport > ( ( toImport ) => ( {
182
- ...toImport ,
183
- values : true ,
184
- } ) ) ,
185
181
{
186
182
name : pascal ( name ) ,
187
183
} ,
188
184
] ,
189
185
schemas : [
190
186
...resolvedData . schemas ,
191
187
{
192
- imports : [ ] ,
188
+ imports : resolvedData . imports . map < GeneratorImport > ( ( toImport ) => ( {
189
+ ...toImport ,
190
+ values : true ,
191
+ } ) ) ,
193
192
model : newEnum ,
194
193
name : pascal ( name ) ,
195
194
} ,
Original file line number Diff line number Diff line change @@ -14,9 +14,14 @@ paths:
14
14
in : query
15
15
schema :
16
16
anyOf :
17
- - type : string
18
- enum : ['A']
17
+ - $ref : ' #/components/schemas/A'
19
18
- type : string
20
19
enum : ['B']
21
20
- type : string
22
21
enum : ['C']
22
+ components :
23
+ schemas :
24
+ A :
25
+ type : string
26
+ enum :
27
+ - A
You can’t perform that action at this time.
0 commit comments