File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -252,16 +252,16 @@ const numberKeywords = [
252
252
* https://datatracker.ietf.org/doc/html/draft-handrews-json-schema-validation-01#section-6
253
253
*/
254
254
function inferTypeByKeyword ( schema ) {
255
- for ( let keyword of objectKeywords ) {
255
+ for ( const keyword of objectKeywords ) {
256
256
if ( keyword in schema ) return 'object'
257
257
}
258
- for ( let keyword of arrayKeywords ) {
258
+ for ( const keyword of arrayKeywords ) {
259
259
if ( keyword in schema ) return 'array'
260
260
}
261
- for ( let keyword of stringKeywords ) {
261
+ for ( const keyword of stringKeywords ) {
262
262
if ( keyword in schema ) return 'string'
263
263
}
264
- for ( let keyword of numberKeywords ) {
264
+ for ( const keyword of numberKeywords ) {
265
265
if ( keyword in schema ) return 'number'
266
266
}
267
267
return schema . type
You can’t perform that action at this time.
0 commit comments