Open nangchan opened 11 months ago
Check Michael Potter pull request https://github.com/diepm/vim-rest-console/pull/94/commits/3179c79acbcfded8988672582ae8d796be44d202
Header names are not case sensitive.
From RFC 2616 - "Hypertext Transfer Protocol -- HTTP/1.1", Section 4.2, "Message Headers":
Each header field consists of a name followed by a colon (":") and the field value. Field names are case-insensitive.
The updating RFC 7230 does not list any changes from RFC 2616 at this part. https://stackoverflow.com/a/5259004
When specifying the header Content-Type, only uppercase "Content-Type" works but lowercase "content-type" is ignored and overridden by g:vrc_header_content_type.
Solution: When the user specifies "content-type" the plugin will automatically uppercase to "Content-Type" to match the existing logic.