Recoverable class method reset_password should use a bang!

This commit is contained in:
Carlos A. da Silva
2009-10-07 23:01:45 -03:00
parent ba7e74e1a1
commit 97ae1795bd
3 changed files with 6 additions and 6 deletions

View File

@@ -20,7 +20,7 @@ class PasswordsController < ApplicationController
end
def update
@password = User.reset_password(params[:password])
@password = User.reset_password!(params[:password])
if @password.errors.empty?
flash[:notice] = 'Your password was changed successfully.'
redirect_to new_session_path