| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
| | | | | | |
|
| |\ \ \ \ \
| | | | | | |
| | | | | | | |
assert_template matches against Regexp
|
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
This allows for more strict template assertions,
while maintaining backward compatibility.
For example, if you use assert_template("foo/bar")
and "foo/bar/baz" was rendered, the test passes.
But if you use assert_template(%r{\Afoo/bar\Z}),
you will catch that a different template was
rendered.
Also, if you passed an unsupported argument to
assert_template() in the past, it would silently
succeed. Now it raises an ArgumentError.
|
| |\ \ \ \ \ \
| | |/ / / / /
| |/| | | | | |
configure how unverified request will be handled
|
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
can be configured using `:with` option in `protect_from_forgery` method
or `request_forgery_protection_method` config option
possible values:
- :reset_session (default)
- :exception
new applications are generated with:
protect_from_forgery :with => :exception
|
| |_|/ / / /
|/| | | | | |
|
|/ / / / / |
|
|\ \ \ \ \
| |/ / / /
|/| | | | |
|
| | | | | |
|
| | | | | |
|
| | | | | |
|
| | | | | |
|
| | | | | |
|
| |/ / /
|/| | |
| | | |
| | | | |
Removed some useless docstrings and no-doc'ed some.
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
We should let the responder to decide what to do with the given
overridden response block, and not short circuit it.
Fixes #5280
|
| | | | |
|
|/ / / |
|
|\ \ \ |
|
| | | |
| | | |
| | | |
| | | | |
max-stale is a cache request header.
|
| | | |
| | | |
| | | |
| | | |
| | | | |
It fails if routes from to railties are called in one context,
for example: blog.posts_path and main_app.users_path
|
| | | | |
|
| | | | |
|
|/ / /
| | |
| | |
| | | |
We have an empty api doc page otherwise :)
|
| | | |
|
| | | |
|
| | | |
|
|\ \ \
| | | |
| | | | |
Add config.default_method_for_update to support PATCH
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
PATCH is the correct HTML verb to map to the #update action. The
semantics for PATCH allows for partial updates, whereas PUT requires a
complete replacement.
Changes:
* adds config.default_method_for_update you can set to :patch
* optionally use PATCH instead of PUT in resource routes and forms
* adds the #patch verb to routes to detect PATCH requests
* adds #patch? to Request
* changes documentation and comments to indicate support for PATCH
This change maintains complete backwards compatibility by keeping :put
as the default for config.default_method_for_update.
|
|/ / /
| | |
| | |
| | |
| | |
| | | |
is being rendered
Closes #5025 part 2
|
| | | |
|
|\ \ \
| | | |
| | | | |
Ensure Date header on expires_in
|
| | | |
| | | |
| | | |
| | | | |
#expires_in
|
| | | | |
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
This fixes undef `to_str' for Rack::Chunked::Body when using
caches_action + streaming on an action
Closes #5027
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
`ActionController.force_ssl` redirects http URLs to their https equivalent;
however, when a URL contains a query string, the resulting redirect lacked the
original query string.
Conflicts:
actionpack/lib/action_controller/metal/force_ssl.rb
|
| | | | |
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Default responder was only using the given respond block when user
requested for HTML format, or JSON/XML format with valid resource. This
fix the responder so that it will use the given block regardless of the
validity of the resource. Note that in this case you'll have to check
for object's validity by yourself in the controller.
Fixes #4796
|
|\ \ \ \
| | | | |
| | | | | |
A little constantize update
|
| | | | | |
|
|/ / / /
| | | |
| | | |
| | | | |
stores.
|
| | | | |
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
* Check for performed? instead of response_body
* Change performed? to return a boolean
* Refactor AC::Metal#response_body= to reuse variable
|
| | | | |
|
|\ \ \ \
| | | | |
| | | | | |
Action controller refactor - remove Compatibility module
|
| | | | | |
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
This should be set globally as a configuration, using
`config.action_dispatch.default_charset` instead
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
This seems to be required only when calling render :partial with an
empty collection from a controller. This call happens to return no
content, letting the response body empty, which means to Rails that it
should go on and try to find a template to render based on the current
action name, thus failing hard.
Although tests keep all green, we need to check a better way to fix
this.
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
instead
Do not create a method_missing method to handle not found actions, use
the action_missing method provided by Rails instead.
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Options :nothing and :text => nil should be handled by
ActionController::Rendering instead.
|
| | | | | |
|