File tree Expand file tree Collapse file tree 1 file changed +11
-4
lines changed
Expand file tree Collapse file tree 1 file changed +11
-4
lines changed Original file line number Diff line number Diff line change @@ -29,7 +29,13 @@ function parseArgumentsIntoOptions(
2929type optionsType = {
3030 language : boolean ;
3131 filePath ?: string ;
32- schemaKeys ?: number | 0 ;
32+ } ;
33+
34+ type missingOptionsType = {
35+ language : any ;
36+ schema : any ;
37+ filePath ?: string ;
38+ schemaKeys ?: number ;
3339} ;
3440
3541type questionType = {
@@ -135,7 +141,9 @@ async function promptForSchemaObject() {
135141
136142async function cli ( args : string [ ] ) {
137143 var options : optionsType = parseArgumentsIntoOptions ( args ) ;
138- options = await promptForMissingOptions ( options ) ;
144+ var missingOptions : missingOptionsType = await promptForMissingOptions (
145+ options
146+ ) ;
139147
140148 const { schemaKeys } = await inquirer . prompt ( {
141149 type : "input" ,
@@ -155,8 +163,7 @@ async function cli(args: string[]) {
155163 schemaKeyValues . push ( objectValues ) ;
156164 }
157165
158- var schema = { ...schemaKeys } ;
159-
166+ var schema = missingOptions . schema ;
160167 await createSchema ( schema , schemaKeyValues ) ;
161168}
162169
You can’t perform that action at this time.
0 commit comments