From: David Gageot Date: Tue, 17 Jul 2012 15:38:07 +0000 (+0200) Subject: FIX SONAR-3667 Unable to change user password X-Git-Tag: 3.2~41 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=57c924f81ad80dee08a3b14777db9cfb0f7ec63d;p=sonarqube.git FIX SONAR-3667 Unable to change user password --- diff --git a/sonar-server/src/main/webapp/WEB-INF/app/controllers/users_controller.rb b/sonar-server/src/main/webapp/WEB-INF/app/controllers/users_controller.rb index a187754727c..1e4fe52d4cd 100644 --- a/sonar-server/src/main/webapp/WEB-INF/app/controllers/users_controller.rb +++ b/sonar-server/src/main/webapp/WEB-INF/app/controllers/users_controller.rb @@ -94,8 +94,10 @@ class UsersController < ApplicationController redirect_to(:action => 'change_password', :id => params[:id]) elsif user.update_attributes(:password => params[:user][:password], :password_confirmation => params[:user][:password_confirmation]) flash[:notice] = 'Password was successfully updated.' - else to_index(user.errors, nil) + else + flash[:error] = user.errors.full_messages.join("
\n") + redirect_to(:action => 'change_password', :id => params[:id]) end end