fix argument bug

when `is_navigational_format?` returns false, Exception will be throw: 
ArgumentError (Nil location provided. Can't build URI.)
This commit is contained in:
Michael Ding 2014-09-29 14:36:05 +08:00
parent 9f63850279
commit 002b4c6c01
1 changed files with 1 additions and 1 deletions

View File

@ -33,7 +33,7 @@ class Devise::ConfirmationsController < DeviseController
# The path used after resending confirmation instructions.
def after_resending_confirmation_instructions_path_for(resource_name)
new_session_path(resource_name) if is_navigational_format?
is_navigational_format? ? new_session_path(resource_name) : '/'
end
# The path used after confirmation.