Class: Trestle::Omniauth::SessionsController
- Inherits:
-
ApplicationController
- Object
- ApplicationController
- Trestle::Omniauth::SessionsController
- Defined in:
- app/controllers/trestle/omniauth/sessions_controller.rb
Instance Method Summary collapse
Instance Method Details
#create ⇒ Object
10 11 12 13 |
# File 'app/controllers/trestle/omniauth/sessions_controller.rb', line 10 def create login!(request.env["omniauth.auth"]) redirect_to previous_location || instance_exec(&Trestle.config.omniauth.redirect_on_login) end |
#destroy ⇒ Object
15 16 17 18 |
# File 'app/controllers/trestle/omniauth/sessions_controller.rb', line 15 def destroy logout! redirect_to instance_exec(&Trestle.config.omniauth.redirect_on_logout) end |
#new ⇒ Object
6 7 8 |
# File 'app/controllers/trestle/omniauth/sessions_controller.rb', line 6 def new @providers = Trestle.config.omniauth.providers.keys end |