diff options
author | James Kiesel <james.kiesel@gmail.com> | 2014-10-09 14:08:33 +0400 |
---|---|---|
committer | James Kiesel <james.kiesel@gmail.com> | 2014-10-09 14:08:33 +0400 |
commit | 2d44107b5d54e99d57360fee024b99c873211e65 (patch) | |
tree | 848e923c4b2cd0b9ff28231801fbebb37140f978 /app | |
parent | d44300c7a2b7bc8bd33ab880134695d0dc75d490 (diff) |
Allow nil HTTP user agent
Diffstat (limited to 'app')
-rw-r--r-- | app/controllers/application_controller.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/controllers/application_controller.rb b/app/controllers/application_controller.rb index f95636f60..327b6068c 100644 --- a/app/controllers/application_controller.rb +++ b/app/controllers/application_controller.rb @@ -36,7 +36,7 @@ class ApplicationController < ActionController::Base def after_sign_out_path_for(resource_or_scope) # mobile_fu's is_mobile_device? wasn't working here for some reason... # it may have been just because of the test env. - if request.env['HTTP_USER_AGENT'].match(/mobile/i) + if request.env['HTTP_USER_AGENT'].try(:match, /mobile/i) root_path else new_user_session_path |