aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/lib/action_dispatch/http/headers.rb
Commit message (Collapse)AuthorAgeFilesLines
* use methods on the request object to implement `fetch`Aaron Patterson2015-08-211-2/+8
| | | | Now the Headers internals don't depend on the env hash.
* dup the env hash on Header#envAaron Patterson2015-08-211-1/+1
| | | | | This prevents external mutations from impacting the internals of the request or the Header object.
* use accessors on the request object for manipulating envAaron Patterson2015-08-211-3/+3
| | | | | this reduces the API footprint for the env hash so that we can be more flexible when changing API in the future
* use `set_header` rather than []=Aaron Patterson2015-08-211-1/+1
| | | | This allows us to avoid calling `env_name` twice.
* dup the request and mutate its headers object.Aaron Patterson2015-08-211-2/+2
| | | | duping the request will dup it's underlying env hash.
* pass a request object to the headers objectAaron Patterson2015-08-211-9/+15
|
* Use a frozen Set instance for CGI_VARIABLES.Nathaniel Bibler2014-06-051-8/+21
| | | Also expand the CGI_VARIABLE name listing to multiple lines for cleaner diffs and legibility.
* Merge branch 'master' of github.com:rails/docrailsVijay Dev2014-05-101-1/+22
|\
| * copy edits [ci skip]Vijay Dev2014-05-101-8/+8
| |
| * [ci skip] doc Http::Headers methodsschneems2014-05-091-1/+17
| |
| * copy edits [ci skip]Vijay Dev2014-05-081-2/+1
| |
| * [ci skip] document ActionDispatch::HTTP::Headersschneems2014-05-071-0/+6
| |
* | HTTP::Headers#key? correctly convertsschneems2014-05-071-1/+3
|/ | | | | | | | | | | | | | | Previously if you were looking for a given key, the header may incorrectly tell you that it did not exist even though it would return a valid value: ```ruby env = { "CONTENT_TYPE" => "text/plain" } headers = ActionDispatch::Http::Headers.new(env) headers["Content-Type"] # => "text/plain" headers.key?("Content-Type") # => false ``` This PR fixes that behavior by converting the key before checking for presence
* `Http::Headers` directly modifies the passed environment.Yves Senn2013-03-151-2/+1
| | | | | | | | | The env hash passed to `Http::Headers#new` must be in env format. Also be aware that the passed hash is modified directly. docs and test-cases for setting headers/env in functional tests. Follow up to #9700.
* `Http::Headers` respects dotted env vars, symbols, headers with numbers.Yves Senn2013-03-131-11/+6
|
* allow headers and env to be passed in `IntegrationTest`.Yves Senn2013-03-131-1/+15
| | | | Closes #6513.
* refactor, `Http::Headers` stores headers in env notationYves Senn2013-03-131-17/+21
| | | | | Also: cleanup, use consistent syntax for `Http::Header` and test.
* Http::Headers respects headers that are not prefixed with HTTP_Yves Senn2013-03-131-1/+13
|
* move cache inside the instance so we do not need lockingAaron Patterson2012-10-181-9/+12
|
* add test for fetch with a blockAaron Patterson2012-10-181-2/+2
|
* prefer composition over inheritenceAaron Patterson2012-10-181-11/+15
|
* Enable ActionDispatch::Http::Headers to support fetchMark Turner2012-05-021-7/+8
|
* Unneeded require memoizableAkira Matsuda2011-11-121-2/+0
|
* Remove usage of memoizable from ActionPack.José Valim2011-06-161-3/+3
|
* Silence some trivial warnings: shadowed local vars, indentation mismatchesJeremy Kemper2009-12-281-7/+7
|
* Move HTTP libs and middleware into ActionDispatch componentJoshua Peek2009-01-271-0/+33