Conversation
Conclusion is a bit falsy. We don't care about the value of
Conclusion is a bit falsy. Here we don't create about the value for sure.
This depends on the pattern matching of
That's fine.
Yeah this is an obvious bug.
|
Execution planWe'll introduce proper support for OpenAPI upload in 3 layers. Layer 1Fix the current code so that
We should compare the
So instead of doing: if(
contentType === "application/octet-stream"
|| contentType.indexOf("image/") === 0
|| contentType.indexOf("audio/") === 0
|| contentType.indexOf("video/") === 0
...
) {We should be doing: if(
contentType.startsWith("application/octet-stream")
|| contentType.startsWith("image/")
|| contentType.startsWith("audio/")
|| contentType.startsWith("video/")
...
) {We should access the JSON Schema Layer 2This layer is OpenAPI 3.1.x specific and modifies Layer 3Handling of new Rules (assuming
There is an ambiguous case for rule 5. |
Related to OpenAPI 3.1.x.
We should now display file input when:
contentEncodingisbase64contentMediaTypeisapplication/octet-stream,image/*,video/*oraudio/*Does not add support for file upload if schema has union type or if
typeandcontentEncoding/contentMediaTypeare defined inoneOf/anyOf.base64vsbyteRefs #9278
Attribution: @glowcloud