aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCheah Chu Yeow <chuyeow@gmail.com>2009-11-20 14:06:42 +0800
committerCheah Chu Yeow <chuyeow@gmail.com>2009-11-20 14:06:42 +0800
commit14ee31cdd09ef100cd2cb9eb9bd50c3a6d5e7f45 (patch)
treee299dff2825063a93dfdb633c4bd8016d5322e7f
parent78c1127a631a628aae54b7febaf9be2e0982e609 (diff)
downloadrails-14ee31cdd09ef100cd2cb9eb9bd50c3a6d5e7f45.tar.gz
rails-14ee31cdd09ef100cd2cb9eb9bd50c3a6d5e7f45.tar.bz2
rails-14ee31cdd09ef100cd2cb9eb9bd50c3a6d5e7f45.zip
Indicate that the :method routing condition can also accept an array of HTTP methods.
-rw-r--r--actionpack/lib/action_dispatch/routing.rb7
1 files changed, 4 insertions, 3 deletions
diff --git a/actionpack/lib/action_dispatch/routing.rb b/actionpack/lib/action_dispatch/routing.rb
index 68ed1e3340..5063ab8072 100644
--- a/actionpack/lib/action_dispatch/routing.rb
+++ b/actionpack/lib/action_dispatch/routing.rb
@@ -193,9 +193,10 @@ module ActionDispatch
#
# With conditions you can define restrictions on routes. Currently the only valid condition is <tt>:method</tt>.
#
- # * <tt>:method</tt> - Allows you to specify which method can access the route. Possible values are <tt>:post</tt>,
- # <tt>:get</tt>, <tt>:put</tt>, <tt>:delete</tt> and <tt>:any</tt>. The default value is <tt>:any</tt>,
- # <tt>:any</tt> means that any method can access the route.
+ # * <tt>:method</tt> - Allows you to specify which HTTP method(s) can access the route. Possible values are
+ # <tt>:post</tt>, <tt>:get</tt>, <tt>:put</tt>, <tt>:delete</tt> and <tt>:any</tt>. Use an array to specify more
+ # than one method, e.g. <tt>[ :get, :post ]</tt>. The default value is <tt>:any</tt>, <tt>:any</tt> means that any
+ # method can access the route.
#
# Example:
#