Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(utils): recognize content types with whitespace #181

Merged
merged 1 commit into from
Feb 28, 2023

Conversation

dpopp07
Copy link
Member

@dpopp07 dpopp07 commented Feb 28, 2023

The RFC for content-type header format allows optional whitespace before the semicolon. Our regular expressions for recognizing various mime types do not account for this, so valid mime types may not be recognized. This commit adjusts the expression to close that gap.

The RFC for content-type header format allows optional whitespace before the
semicolon. Our regular expressions for recognizing various mime types do not
account for this, so valid mime types may not be recognized. This commit
adjusts the expression to close that gap.

Signed-off-by: Dustin Popp <[email protected]>
@dpopp07 dpopp07 requested a review from padamstx February 28, 2023 14:33
Copy link
Member

@padamstx padamstx left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@dpopp07 dpopp07 merged commit 09fe5cf into main Feb 28, 2023
@dpopp07 dpopp07 deleted the dp/json-mimetype-whitespace branch February 28, 2023 14:50
ibm-devx-sdk pushed a commit that referenced this pull request Feb 28, 2023
## [5.13.1](v5.13.0...v5.13.1) (2023-02-28)

### Bug Fixes

* **utils:** recognize content types with whitespace ([#181](#181)) ([09fe5cf](09fe5cf))
@ibm-devx-sdk
Copy link

🎉 This PR is included in version 5.13.1 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants