diff --git a/app/controllers/account_controller.rb b/app/controllers/account_controller.rb index 4355616f5c..6fe8bd1c13 100644 --- a/app/controllers/account_controller.rb +++ b/app/controllers/account_controller.rb @@ -338,8 +338,9 @@ class AccountController < ApplicationController end def redirect_if_password_change_not_allowed(user) - logger.warn "Password change for user '#{user}' forced, but user is not allowed to change password" if user and not user.change_password_allowed? + logger.warn "Password change for user '#{user}' forced, but user is not allowed " + + "to change password" flash[:error] = l(:notice_can_t_change_password) redirect_to :action => 'login' return true