1
0
mirror of https://github.com/LaCasemate/fab-manager.git synced 2024-11-29 10:24:20 +01:00
fab-manager/app/controllers/sessions_controller.rb

15 lines
355 B
Ruby
Raw Normal View History

# frozen_string_literal: true
# Devise controller for handling client sessions
2015-05-05 03:10:25 +02:00
class SessionsController < Devise::SessionsController
2016-03-23 18:39:41 +01:00
def new
active_provider = AuthProvider.active
if active_provider.providable_type != DatabaseProvider.name
redirect_to "/users/auth/#{active_provider.strategy_name}"
2016-03-23 18:39:41 +01:00
else
super
end
end
2015-05-05 03:10:25 +02:00
end