File tree Expand file tree Collapse file tree 2 files changed +4
-2
lines changed
src/Microsoft.OpenApi/Models
test/Microsoft.OpenApi.Tests/Models Expand file tree Collapse file tree 2 files changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -259,7 +259,8 @@ public void SerializeAsV2WithoutReference(IOpenApiWriter writer)
259
259
}
260
260
// In V2 parameter's type can't be a reference to a custom object schema or can't be of type object
261
261
// So in that case map the type as string.
262
- else if ( Schema ? . UnresolvedReference == false || Schema ? . Type == "object" )
262
+ else
263
+ if ( Schema ? . UnresolvedReference == true || Schema ? . Type == "object" )
263
264
{
264
265
writer . WriteProperty ( OpenApiConstants . Type , "string" ) ;
265
266
}
Original file line number Diff line number Diff line change @@ -73,7 +73,8 @@ public class OpenApiParameterTests
73
73
{
74
74
Type = ReferenceType . Schema ,
75
75
Id = "schemaObject1"
76
- }
76
+ } ,
77
+ UnresolvedReference = true
77
78
} ,
78
79
Examples = new Dictionary < string , OpenApiExample >
79
80
{
You can’t perform that action at this time.
0 commit comments