@@ -1523,6 +1523,18 @@ let QUERYPARAM = 'query',
1523
1523
return [ { [ bodyKey ] : bodyData } ] ;
1524
1524
}
1525
1525
1526
+ // For type fetching, process the original schema before any modifications
1527
+ if ( context . enableTypeFetching && requestBodySchema ) {
1528
+ // Get the actual schema - it might be nested under .schema or be direct
1529
+ const originalSchema = requestBodySchema . schema || requestBodySchema ,
1530
+ resolvedSchema = resolveSchema (
1531
+ context ,
1532
+ originalSchema ,
1533
+ { resolveFor : 'PROCESSING' } ) ,
1534
+ requestBodySchemaTypes = processSchema ( resolvedSchema ) ;
1535
+ requestBodySchemaTypes && resolvedSchemaTypes . push ( requestBodySchemaTypes ) ;
1536
+ }
1537
+
1526
1538
if ( requestBodySchema . $ref ) {
1527
1539
requestBodySchema = resolveSchema (
1528
1540
context ,
@@ -1531,14 +1543,6 @@ let QUERYPARAM = 'query',
1531
1543
) ;
1532
1544
}
1533
1545
1534
- // For type fetching, process the original schema before any modifications
1535
- if ( context . enableTypeFetching && requestBodySchema ) {
1536
- // Get the actual schema - it might be nested under .schema or be direct
1537
- const originalSchema = requestBodySchema . schema || requestBodySchema ,
1538
- requestBodySchemaTypes = processSchema ( originalSchema ) ;
1539
- resolvedSchemaTypes . push ( requestBodySchemaTypes ) ;
1540
- }
1541
-
1542
1546
/**
1543
1547
* We'll be picking up example data from `value` only if
1544
1548
* `value` is the only key present at the root level;
0 commit comments