diff options
author | Sean McGivern <sean@gitlab.com> | 2016-05-03 14:42:55 +0300 |
---|---|---|
committer | Sean McGivern <sean@gitlab.com> | 2016-05-16 11:21:24 +0300 |
commit | bec350528cdc81e26476780f1ca3db8171b3ece8 (patch) | |
tree | 31e273cd2202ad4e2647d127d464dd1c31b52ded /app/controllers/admin/users_controller.rb | |
parent | 78a67fc48dab434b43a080e5b15491963656661a (diff) |
Force password change after admin reset
When an admin changes a user's password for them, force the user to
reset the password after logging in by expiring the new password
immediately.
Diffstat (limited to 'app/controllers/admin/users_controller.rb')
-rw-r--r-- | app/controllers/admin/users_controller.rb | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/app/controllers/admin/users_controller.rb b/app/controllers/admin/users_controller.rb index f2f654c7bcd..6908a3bf946 100644 --- a/app/controllers/admin/users_controller.rb +++ b/app/controllers/admin/users_controller.rb @@ -119,6 +119,7 @@ class Admin::UsersController < Admin::ApplicationController user_params_with_pass.merge!( password: params[:user][:password], password_confirmation: params[:user][:password_confirmation], + password_expires_at: Time.now ) end |