-
Notifications
You must be signed in to change notification settings - Fork 47
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
chore: Allow text/plain content type descriptor for json formatted content body #2209
Conversation
…ody. Refactored duplicated encode/decode functions for rest api
You can find the image built from this PR at
Built from 5ff6902 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Didn't have time to actually run it, but from visual sanity check perspective it looks great (thanks for the refactoring!)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thanks so much!
As @weboko pointed out, I missed converting /relay apis to accept text/plain requests, it is done now with some simplifications |
Amazing, now it works. I noticed some of improvements that can be done:
|
Do not set it to The CORS origin should only be |
…itional parameters are present
Added support for decoding content body when content-type header argument has more parameters above media type. |
Browser recognizes CORS based on Same origin policy which unfortunately takes port into account, so event if it is same domain but ports are different it violates If REST is intended to be user only locally - it should be enough with MIME change in this PR. |
Yes, REST should be user only locally. |
Description
@weboko requested that from browser no-coors mode we need to supprt text/plain content-body requests.
Changes
How to test
Issue
#2207