aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack
diff options
context:
space:
mode:
authorPhilipe Fatio <me@phili.pe>2013-12-14 15:35:50 +0100
committerPhilipe Fatio <me@phili.pe>2013-12-14 15:35:50 +0100
commitfd76b9d5469c3309ce4308fda5bc9e95cbc457f8 (patch)
tree585fa12b12a08e110df3b171148440f12f26679e /actionpack
parent068580d4456e881e568de4a4d20a401e87b6c9e1 (diff)
downloadrails-fd76b9d5469c3309ce4308fda5bc9e95cbc457f8.tar.gz
rails-fd76b9d5469c3309ce4308fda5bc9e95cbc457f8.tar.bz2
rails-fd76b9d5469c3309ce4308fda5bc9e95cbc457f8.zip
Fix syntax error in redirect_to example
Without parenthesis, ruby assumes that curly braces denote the beginning of a block.
Diffstat (limited to 'actionpack')
-rw-r--r--actionpack/lib/action_controller/metal/redirecting.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/actionpack/lib/action_controller/metal/redirecting.rb b/actionpack/lib/action_controller/metal/redirecting.rb
index ab14a61b97..2812038938 100644
--- a/actionpack/lib/action_controller/metal/redirecting.rb
+++ b/actionpack/lib/action_controller/metal/redirecting.rb
@@ -58,7 +58,7 @@ module ActionController
# redirect_to post_url(@post), alert: "Watch it, mister!"
# redirect_to post_url(@post), status: :found, notice: "Pay attention to the road"
# redirect_to post_url(@post), status: 301, flash: { updated_post_id: @post.id }
- # redirect_to { action: 'atom' }, alert: "Something serious happened"
+ # redirect_to({ action: 'atom' }, alert: "Something serious happened")
#
# When using <tt>redirect_to :back</tt>, if there is no referrer, ActionController::RedirectBackError will be raised. You may specify some fallback
# behavior for this case by rescuing ActionController::RedirectBackError.