Commit d57fea4f authored by Valery Sizov's avatar Valery Sizov

Minor backport from EE

parent 905d3ed4
...@@ -13,7 +13,7 @@ class SessionsController < Devise::SessionsController ...@@ -13,7 +13,7 @@ class SessionsController < Devise::SessionsController
before_action :auto_sign_in_with_provider, only: [:new] before_action :auto_sign_in_with_provider, only: [:new]
before_action :load_recaptcha before_action :load_recaptcha
after_action :log_failed_login, only: [:new] after_action :log_failed_login, only: [:new], if: :failed_login?
def new def new
set_minimum_password_length set_minimum_password_length
...@@ -46,8 +46,6 @@ class SessionsController < Devise::SessionsController ...@@ -46,8 +46,6 @@ class SessionsController < Devise::SessionsController
private private
def log_failed_login def log_failed_login
return unless failed_login?
Gitlab::AppLogger.info("Failed Login: username=#{user_params[:login]} ip=#{request.remote_ip}") Gitlab::AppLogger.info("Failed Login: username=#{user_params[:login]} ip=#{request.remote_ip}")
end end
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment