Skip to content

Commit b8d0d2b

Browse files
committed
Default to V3 of OpenApi during document serialization
1 parent 5550f01 commit b8d0d2b

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/Microsoft.OpenApi.Hidi/OpenApiService.cs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright (c) Microsoft Corporation. All rights reserved.
1+
// Copyright (c) Microsoft Corporation. All rights reserved.
22
// Licensed under the MIT license.
33

44
using System;
@@ -87,8 +87,9 @@ string filterbycollection
8787

8888
if (!string.IsNullOrEmpty(csdl))
8989
{
90-
// Default to yaml during csdl to OpenApi conversion
90+
// Default to yaml and OpenApiVersion 3 during csdl to OpenApi conversion
9191
openApiFormat = format ?? GetOpenApiFormat(csdl, logger);
92+
version ??= OpenApiSpecVersion.OpenApi3_0;
9293

9394
stream = await GetStream(csdl, logger);
9495
document = ConvertCsdlToOpenApi(stream);

0 commit comments

Comments
 (0)