Class: Stall::OmniauthCallbacksController
- Inherits:
-
Devise::OmniauthCallbacksController
- Object
- Devise::OmniauthCallbacksController
- Stall::OmniauthCallbacksController
- Includes:
- OmniauthHelper
- Defined in:
- app/controllers/stall/omniauth_callbacks_controller.rb
Instance Method Summary collapse
- #facebook ⇒ Object
- #google_oauth2 ⇒ Object
-
#redirect ⇒ Object
Pre-authorize request to store the redirect path, allowing users to get back to the checkout wether the authentication is successful or not.
Methods included from OmniauthHelper
#user_omniauth_authorize_path_for
Instance Method Details
#facebook ⇒ Object
13 14 15 |
# File 'app/controllers/stall/omniauth_callbacks_controller.rb', line 13 def facebook authenticate_user_from_oauth_callback! end |
#google_oauth2 ⇒ Object
17 18 19 |
# File 'app/controllers/stall/omniauth_callbacks_controller.rb', line 17 def google_oauth2 authenticate_user_from_oauth_callback! end |
#redirect ⇒ Object
Pre-authorize request to store the redirect path, allowing users to get back to the checkout wether the authentication is successful or not.
8 9 10 11 |
# File 'app/controllers/stall/omniauth_callbacks_controller.rb', line 8 def redirect session['omniauth.after_sign_in_redirect_path'] = params[:_redirect_to] if params[:_redirect_to] redirect_to (params[:provider]) end |