diff options
author | Neeraj Singh <neerajdotname@gmail.com> | 2010-11-22 08:58:01 -0500 |
---|---|---|
committer | José Valim <jose.valim@gmail.com> | 2010-11-22 23:06:12 +0100 |
commit | eb6ccc9953a5e952737174995b5230f0b2c56b1f (patch) | |
tree | 94c49b3e4d5647ad249b1407b527e33e72aa37e9 /actionpack/lib | |
parent | f5fba917f8dbf45fcbf04b4b26cf54eb3b300057 (diff) | |
download | rails-eb6ccc9953a5e952737174995b5230f0b2c56b1f.tar.gz rails-eb6ccc9953a5e952737174995b5230f0b2c56b1f.tar.bz2 rails-eb6ccc9953a5e952737174995b5230f0b2c56b1f.zip |
do not assume that there is no space between
leading */* and comma
Signed-off-by: José Valim <jose.valim@gmail.com>
Diffstat (limited to 'actionpack/lib')
-rw-r--r-- | actionpack/lib/action_dispatch/http/mime_negotiation.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/actionpack/lib/action_dispatch/http/mime_negotiation.rb b/actionpack/lib/action_dispatch/http/mime_negotiation.rb index afce4d9651..2b401114f0 100644 --- a/actionpack/lib/action_dispatch/http/mime_negotiation.rb +++ b/actionpack/lib/action_dispatch/http/mime_negotiation.rb @@ -48,7 +48,7 @@ module ActionDispatch @env["action_dispatch.request.formats"] ||= if parameters[:format] Array(Mime[parameters[:format]]) - elsif xhr? || (accept && accept !~ /,\s*\*\/\*|\*\/\*,/) + elsif xhr? || (accept && accept !~ /,\s*\*\/\*|\*\/\*\s*,/) accepts else [Mime::HTML] |