File tree Expand file tree Collapse file tree 2 files changed +3
-10
lines changed
packages/openapi-ts/src/openApi Expand file tree Collapse file tree 2 files changed +3
-10
lines changed Original file line number Diff line number Diff line change @@ -73,14 +73,11 @@ export const paginationField = ({
73
73
}
74
74
75
75
for ( const name in schema . properties ) {
76
- const paginationRegExp = getPaginationKeywordsRegExp ( config ) ;
76
+ const paginationRegExp = getPaginationKeywordsRegExp ( context . config ) ;
77
77
paginationRegExp . lastIndex = 0 ;
78
78
79
79
if ( paginationRegExp . test ( name ) ) {
80
- const property = schema . properties [ name ] ;
81
-
82
- // Skip if property doesn't exist
83
- if ( ! property ) continue ;
80
+ const property = schema . properties [ name ] ! ;
84
81
85
82
if ( typeof property !== 'boolean' && ! ( '$ref' in property ) ) {
86
83
const schemaType = getSchemaType ( { schema : property } ) ;
@@ -95,7 +92,6 @@ export const paginationField = ({
95
92
96
93
for ( const allOf of schema . allOf ?? [ ] ) {
97
94
const pagination = paginationField ( {
98
- config,
99
95
context,
100
96
name,
101
97
schema : allOf ,
Original file line number Diff line number Diff line change @@ -73,10 +73,7 @@ export const paginationField = ({
73
73
paginationRegExp . lastIndex = 0 ;
74
74
75
75
if ( paginationRegExp . test ( name ) ) {
76
- const property = schema . properties [ name ] ;
77
-
78
- // Skip if property doesn't exist
79
- if ( ! property ) continue ;
76
+ const property = schema . properties [ name ] ! ;
80
77
81
78
if ( typeof property !== 'boolean' ) {
82
79
// TODO: resolve deeper references
You can’t perform that action at this time.
0 commit comments