diff options
author | Valery Sizov <valery@gitlab.com> | 2017-10-05 14:40:49 +0300 |
---|---|---|
committer | Valery Sizov <valery@gitlab.com> | 2017-10-05 14:40:49 +0300 |
commit | d57fea4f2d394d879024b7a2ff3533f89f025e9f (patch) | |
tree | 3472e59084f8637e02d022fdada9b967e60abfbb /app/controllers/sessions_controller.rb | |
parent | 905d3ed4292e6b274ac51b26b3b3577087c5f737 (diff) | |
download | gitlab-ce-d57fea4f2d394d879024b7a2ff3533f89f025e9f.tar.gz |
Minor backport from EEbackport_from_EE
Diffstat (limited to 'app/controllers/sessions_controller.rb')
-rw-r--r-- | app/controllers/sessions_controller.rb | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/app/controllers/sessions_controller.rb b/app/controllers/sessions_controller.rb index 4223c6171a6..ada91694fd6 100644 --- a/app/controllers/sessions_controller.rb +++ b/app/controllers/sessions_controller.rb @@ -13,7 +13,7 @@ class SessionsController < Devise::SessionsController before_action :auto_sign_in_with_provider, only: [:new] before_action :load_recaptcha - after_action :log_failed_login, only: [:new] + after_action :log_failed_login, only: [:new], if: :failed_login? def new set_minimum_password_length @@ -46,8 +46,6 @@ class SessionsController < Devise::SessionsController private def log_failed_login - return unless failed_login? - Gitlab::AppLogger.info("Failed Login: username=#{user_params[:login]} ip=#{request.remote_ip}") end |