wycats
ab1407cc5b
Improve performance of commonly used request methods
2010-06-04 20:11:04 -07:00
José Valim
941b653627
Rely on set and delete cookie logic from rack.
2010-05-18 01:51:45 +02:00
Santiago Pastorino
961aa70e4a
Some require indifferent_access added
...
Signed-off-by: Xavier Noria <fxn@ubuntu.(none)>
2010-04-21 07:45:29 -07:00
wycats
457f7709e9
Missing requires
2010-04-16 21:59:09 -04:00
wycats
ab8bf9e152
* Change the object used in routing constraints to be an instance of
...
ActionDispatch::Request rather than Rack::Request.
* Changed ActionDispatch::Request#method to return a String, to be
compatible with the Rack::Request superclass.
* Changed ActionDispatch::Request#method to return the original
method in the case of methodoverride and #request_method not to,
to be compatible with Rack::Request
2010-04-03 20:24:30 -07:00
Paul Sadauskas
dc5300adb6
Slightly less annoying check for acceptable mime_types. This allows Accept: application/json, application/jsonp (and the like), but still blacklists browsers. Essentially, we use normal content negotiation unless you include */* in your list, in which case we assume you're a browser and send HTML [ #3541 state:resolved]
2010-04-01 17:42:46 -07:00
wycats
77a2a3d9b3
Request#content_type exists in Rack::Request, and other parts of Rack::Request expect
...
it to return a String. Split the Rails API so that Request#content_type returns
a String, and Request#content_mime_type returns a Mime::Type object.
2010-03-28 13:40:38 -07:00
Xavier Noria
76f024ac8d
adds missing requires for Object#blank? and Object#present?
2010-03-28 14:15:02 +02:00
Xavier Noria
105f9b8154
adds missing requires for Object#duplicable?
2010-03-28 13:26:13 +02:00
José Valim
525382f638
Clean up Mime::Type and remove deprecated stuff (from 2.3).
2010-03-20 00:28:27 +01:00
wycats
cd9ffd11e1
Eliminate warnings for AM on 1.8
2010-03-16 23:24:00 -07:00
José Valim
ec0973c2ab
Remove uneeded methods.
2010-03-10 16:44:24 +01:00
Carlhuda
146a5305d5
Add memoizing to AD::Request
2010-03-08 16:50:00 -08:00
Carlhuda
52efbdcdef
Add caller to request_uri deprecation notice
2010-03-03 21:24:00 -08:00
Carlhuda
93422af5d5
Move remote_ip to a middleware:
...
* ActionController::Base.ip_spoofing_check deprecated => config.action_dispatch.ip_spoofing_check
* ActionController::Base.trusted_proxies deprecated => config.action_dispatch.trusted_proxies
2010-03-03 21:24:00 -08:00
Carl Lerche
fb14b8c6fd
ActionDispatch::Request deprecates #request_uri
...
* Refactored ActionPatch to use fullpath instead
2010-03-03 21:24:00 -08:00
Carl Lerche
c92d598abf
Rack::Request actually defines #query_string
2010-03-03 21:23:59 -08:00
Carlhuda
5e0a05b8cb
Tweak the semantic of various URL related methods of ActionDispatch::Request
2010-03-03 21:23:34 -08:00
Joshua Peek
fef7a77386
Request#subdomain returns a string version of Request#subdomains
2010-02-28 17:16:34 -06:00
Carlhuda
faf3c2f827
Set the body using the accessor for AD::Response introspection mode so it gets wrapped in a []
2010-02-26 18:24:55 -08:00
Carlhuda
a73f682e43
Make AD::Response correctly handle bodies that respond_to?(:to_path) as per the Rack spec
2010-02-23 16:29:29 -08:00
José Valim
55ae903c3f
Store compiled parameter filters so we don't have to compile them in each request.
2010-02-21 14:29:40 +01:00
Carlhuda
a3c6ad7d5e
Fix a bunch of pending tests by providing an introspection mode for the Response object that does up-front parsing of the headers to populate things like @etag
2010-02-19 19:19:20 -08:00
José Valim
fc4f237864
Make filter parameters based on request, so they can be modified for anything in the middleware stack.
2010-01-21 16:52:49 +01:00
José Valim
31fddf2ace
Tidy up new filter_parameters implementation.
2010-01-21 11:57:24 +01:00
Prem Sichanugrist
bd4f21fbac
Move filter_parameter_logging logic out of the controller and create ActionDispatch::ParametersFilter to handle parameter filteration instead. This will make filteration not depending on controller anymore.
...
Signed-off-by: José Valim <jose.valim@gmail.com >
2010-01-21 10:08:26 +01:00
Joshua Peek
87bcf1aa15
Request#filter_parameters and filter_env
2010-01-20 09:55:58 -06:00
Joshua Peek
d2d4acf027
Cookies middleware
2010-01-16 17:22:27 -06:00
José Valim
92f49b5f1e
Split ActionDispatch http in smaller chunks.
2010-01-16 15:45:07 +01:00
Joshua Peek
ead93c5be5
Move Flash into middleware
2010-01-15 14:55:13 -06:00
Joshua Peek
3eaf525213
Make HEAD method masquerade as GET so requests are routed correctly
2010-01-15 12:38:50 -06:00
Yehuda Katz
cf4978313b
Make sure evalled method knows where it came from
2009-12-29 01:04:32 -08:00
Jeremy Kemper
9a650a6547
Silence some trivial warnings: shadowed local vars, indentation mismatches
2009-12-28 17:36:08 -08:00
Joshua Peek
df7faef68e
Referer and user agent are in Rack::Request
2009-12-22 16:09:41 -06:00
Joshua Peek
a1bf2f96ce
AD::StatusCodes support is now part of rack
2009-12-22 16:08:03 -06:00
Joshua Peek
15f95621d5
We don't need AD parse_config
2009-12-20 21:11:42 -06:00
Yehuda Katz
17f66473bc
AC::Head now doesn't have an unfulfilled Rendering dependency, and instead works just fine standalone (which means that ConditionalGet also doesn't have a Rendering dependency)
2009-12-20 18:50:54 -08:00
David Heinemeier Hansson
cf9d6a95e8
Added ActionDispatch::Request#authorization to access the http authentication header regardless of its proxy hiding [DHH]
2009-12-20 18:30:50 -08:00
Joshua Peek
2419fae092
Pending tests for AD Response
2009-12-17 22:10:37 -06:00
Joshua Peek
2130566acf
Fix warnings in AD::Response
2009-12-14 15:47:52 -06:00
Joshua Peek
018dafe574
Allow autoloads to opt out of eager loading
2009-12-12 18:41:26 -06:00
Joshua Peek
1b82590c36
Reduce usage of interpret_status. It should also return a integer
...
not a string.
2009-12-10 22:02:50 -06:00
Jeremy Kemper
de40bc033a
Ensure Cache-Control max-age is an integer
2009-12-02 03:23:00 -08:00
Joshua Peek
ad26f066fe
Response#write is defined twice (this is why -w is good)
2009-12-01 23:29:28 -06:00
Joshua Peek
f22db809c9
Response#cache_control is defined later
2009-12-01 23:27:40 -06:00
Jeremy Kemper
3f54f3100b
Ruby 1.9.2: StringIO no longer has #path
2009-11-13 13:10:28 -08:00
Xavier Noria
f8e713f488
Object#tap is not needed for Ruby >= 1.8.7
2009-11-09 22:16:51 +01:00
Jeremy Kemper
a595abff21
Unknown :format param should result in empty request.formats
2009-11-08 12:12:58 -08:00
Yehuda Katz
e1b5e3cc70
Break up inflector to reduce the dependency burden on dependency-les methods like constantize.
2009-11-07 11:23:21 -08:00
Yehuda Katz
51c24ae3e3
Caching refactoring
2009-10-29 00:44:12 -04:00