devise

https://github.com/plataformatec/devise

Ruby

Flexible authentication solution for Rails with Warden.

Devise::Controllers::StoreLocation#store_location_for

Stores the provided location to redirect the user after signing in.
Useful in combination with the `stored_location_for` helper.

Example:

  store_location_for(:user, dashboard_path)
  redirect_to user_omniauth_authorize_path(:facebook)

Source | Google | Stack overflow

Edit

git clone [email protected]:plataformatec/devise.git

cd devise

open lib/devise/controllers/store_location.rb

Contribute

# Make a new branch

git checkout -b -your-name--update-docs-Devise--Controllers--StoreLocation-store_location_for-for-pr


# Commit to git

git add lib/devise/controllers/store_location.rbgit commit -m "better docs for Devise::Controllers::StoreLocation#store_location_for"


# Open pull request

gem install hub # on a mac you can `brew install hub`

hub fork

git push <your name> -your-name--update-docs-Devise--Controllers--StoreLocation-store_location_for-for-pr

hub pull-request


# Celebrate!