-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
A collection of general API improvements
- Working with Conn APIs requires calling new/0 or new/1 first old APIs are deprecated - new/1 parses the provided string with URI.parse/1 and sets the Conn struct fields accordingly (so you can pass full or partial url fragments and get what you would expect, including those containing query strings) - All headers are normalized to lower-case on put/get, and internally headers are a simple key/value map instead of the previous key => key/value map, which was unnecessary. - Implemented get_req_headers/1, deprecated get_req_header/1 - Implemented put_req_headers/2, deprecated put_req_header/2 - get_req_header/2 returns String.t instead of {String.t, String.t} - get_req_headers/1 returns %{String.t => String.t} instead of %{String.t => %{String.t => String.t}} - Added a number of typespecs, and fixed invalid ones - Some small style fixes, documentation updates - Fixed a bug with the Header middleware which was not overriding headers in the connection if already set. This one may be up for discussion if what's really desired.
- Loading branch information
Showing
19 changed files
with
477 additions
and
420 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.