-
Notifications
You must be signed in to change notification settings - Fork 7
Open
Description
Devise method stored_location_for has a side effect, it removes the value in session['user_return_to'].
Here you use it:
| devise_stored_location = stored_location_for(resource) # Grab the current stored location before it gets lost by warden.logout |
But you only restore it when otp_challenge_required_on? is true. So in the else branch, the initial stored_location_for is lost. I suggest either:
- restore the value in all cases
- store devise_stored_location only in the otp_challenge_required_on? branch.
What do you think?
Metadata
Metadata
Assignees
Labels
No labels