File tree 1 file changed +6
-6
lines changed
1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -95,18 +95,18 @@ const getMockScalarJsTypes = (
95
95
switch ( type ) {
96
96
case 'number' :
97
97
return isArray
98
- ? `Array.from({length: faker.datatype. number({` +
98
+ ? `Array.from({length: faker.number.int ({` +
99
99
`min: ${ mockOptionsWithoutFunc . arrayMin } , ` +
100
100
`max: ${ mockOptionsWithoutFunc . arrayMax } }` +
101
- `)}, () => faker.datatype. number())`
102
- : 'faker.datatype. number().toString()' ;
101
+ `)}, () => faker.number.int ())`
102
+ : 'faker.number.int ().toString()' ;
103
103
case 'string' :
104
104
return isArray
105
- ? `Array.from({length: faker.datatype. number({` +
105
+ ? `Array.from({length: faker.number.int ({` +
106
106
`min: ${ mockOptionsWithoutFunc ?. arrayMin } ,` +
107
107
`max: ${ mockOptionsWithoutFunc ?. arrayMax } }` +
108
- `)}, () => faker.random. word())`
109
- : 'faker.random. word()' ;
108
+ `)}, () => faker.word.sample ())`
109
+ : 'faker.word.sample ()' ;
110
110
default :
111
111
return 'undefined' ;
112
112
}
You can’t perform that action at this time.
0 commit comments