diff options
author | David Heinemeier Hansson <david@loudthinking.com> | 2005-01-10 01:27:39 +0000 |
---|---|---|
committer | David Heinemeier Hansson <david@loudthinking.com> | 2005-01-10 01:27:39 +0000 |
commit | 576b1627254ff0d40063312d7df876706a87eba6 (patch) | |
tree | 6b03c5cd43a2e1214154b4c25d7f7961b6c6b0c5 /actionpack/lib/action_controller | |
parent | e96c08b1aaf1a03a22ec745914d975b6badf0e69 (diff) | |
download | rails-576b1627254ff0d40063312d7df876706a87eba6.tar.gz rails-576b1627254ff0d40063312d7df876706a87eba6.tar.bz2 rails-576b1627254ff0d40063312d7df876706a87eba6.zip |
Added that all renders and redirects now return false, so they can be used as the last line in before_filters to stop execution.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@364 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'actionpack/lib/action_controller')
-rwxr-xr-x | actionpack/lib/action_controller/base.rb | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/actionpack/lib/action_controller/base.rb b/actionpack/lib/action_controller/base.rb index dbdce1bbfd..33e3014ee9 100755 --- a/actionpack/lib/action_controller/base.rb +++ b/actionpack/lib/action_controller/base.rb @@ -389,6 +389,7 @@ module ActionController #:nodoc: @response.headers["Status"] = status || DEFAULT_RENDER_STATUS_CODE @response.body = block_given? ? block : text @performed_render = true + return false end # Renders an empty response that can be used when the request is only interested in triggering an effect. Do note that good @@ -543,6 +544,7 @@ module ActionController #:nodoc: logger.info("Redirected to #{url}") unless logger.nil? @response.redirect(url, permanently) @performed_redirect = true + return false end # Resets the session by clearsing out all the objects stored within and initializing a new session object. |