-
Notifications
You must be signed in to change notification settings - Fork 807
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Ensure embedded spec contains all necessary OpenAPI documents
When using a schema that uses `$ref`s to an external file, although we generate the mappings appropriately, this then leads to the embedded spec being misaligned, as it continues to use the `$ref` to that external file, which then is not available when calling i.e. `GetSwagger`. We can take advantage of the `InternalizeRefs` method to perform an in-place modification to apply those external references into a single, embeddable spec. This appears to only work when a full file is referenced, instead of a path within a file.
- Loading branch information
1 parent
45eb6bd
commit 350fdda
Showing
5 changed files
with
21 additions
and
8 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
{ | ||
"type": "object", | ||
"properties": {}, | ||
"additionalProperties": true | ||
} | ||
|
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters