Skip to content
This repository has been archived by the owner on Nov 28, 2022. It is now read-only.

fix: adding support for handling requestBody if its in a $ref #847

Merged
merged 2 commits into from
Jul 17, 2020

Conversation

erunion
Copy link
Member

@erunion erunion commented Jul 17, 2020

🧰 What's being changed?

This updates @readme/oas-tooling to resolve a bug where operation.getContentType() couldn't handle requestBody schemas that were stored in a $ref. This was exposed as a bug in a multipart/form-data request that was being improperly treated as application/json as since getContentType() didn't see any request bodies, it would default to JSON.

See readmeio/oas#227 for that fix.

Resolves https://app.asana.com/0/1177947654981875/1175486497688586/f

🧪 Testing

You can see this broken here: http://bin.readme.com/s/5f12033dc8a6fe0024c39488

Screen Shot 2020-07-17 at 1 00 26 PM

And fixed:

Screen Shot 2020-07-17 at 12 59 50 PM

📖 Release Notes

3.5.4 (2020-07-17)

3.5.3 (2020-07-16)

@erunion erunion added type:bug Something isn't working scope:dependency Pull requests that update a dependency file area:explorer labels Jul 17, 2020
@erunion erunion requested review from kanadgupta and gratcliff July 17, 2020 20:06
@erunion erunion merged commit 7f80255 into next Jul 17, 2020
@erunion erunion deleted the fix/multipart-form-data-issues branch July 17, 2020 23:51
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
scope:dependency Pull requests that update a dependency file type:bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants