Skip to content

Commit 935fa2b

Browse files
authored
Merge pull request #1232 from json-api-dotnet/remove-sorted-dict-workaround
Remove temporary workaround: SortedDictionary in CachingSwaggerGenerator
2 parents 0e74591 + 9f5bb86 commit 935fa2b

File tree

1 file changed

+1
-8
lines changed

1 file changed

+1
-8
lines changed

src/JsonApiDotNetCore.OpenApi/SwaggerComponents/CachingSwaggerGenerator.cs

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -28,13 +28,6 @@ public OpenApiDocument GetSwagger(string documentName, string? host = null, stri
2828

2929
string cacheKey = $"{documentName}#{host}#{basePath}";
3030

31-
return _openApiDocumentCache.GetOrAdd(cacheKey, _ =>
32-
{
33-
OpenApiDocument document = _defaultSwaggerGenerator.GetSwagger(documentName, host, basePath);
34-
35-
// Remove once https://github.com/domaindrivendev/Swashbuckle.AspNetCore/issues/2283 is addressed.
36-
document.Components.Schemas = new SortedDictionary<string, OpenApiSchema>(document.Components.Schemas, StringComparer.Ordinal);
37-
return document;
38-
});
31+
return _openApiDocumentCache.GetOrAdd(cacheKey, _ => _defaultSwaggerGenerator.GetSwagger(documentName, host, basePath));
3932
}
4033
}

0 commit comments

Comments
 (0)