From 7e5c998a87ef776276c8015c17cd9e7be79a1692 Mon Sep 17 00:00:00 2001 From: Tom Hughes Date: Sun, 9 May 2010 08:44:17 +0100 Subject: [PATCH] Only set pending users to active on a password reset When resetting a password only activate pending users, otherwise a confirmed user's account gets set back to active and may then get suspended by the spam scorer. --- app/controllers/user_controller.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/controllers/user_controller.rb b/app/controllers/user_controller.rb index 222840a06..42a50582e 100644 --- a/app/controllers/user_controller.rb +++ b/app/controllers/user_controller.rb @@ -129,7 +129,7 @@ class UserController < ApplicationController if params[:user] @user.pass_crypt = params[:user][:pass_crypt] @user.pass_crypt_confirmation = params[:user][:pass_crypt_confirmation] - @user.status = "active" + @user.status = "active" if @user.status == "pending" @user.email_valid = true if @user.save -- 2.43.2