plataformatec/devise — pull request #1535 by bkno (2011-12-31 01:12:58+00:00)
Title: update_with_password_unchecked

Hi,

I have been using Active Admin which uses Devise and to my knowledge there is no current way for an admin to set passwords for a user through the backend, as the existing method would require the admin to be aware of that user's current_password. A scenario that this does not fit is when an admin needs to create/update a client account in a CMS (whether Active Admin or another).

I have added a new method "update_with_password_unchecked" to database_authenticable.rb to address this. It is in the same style as "update_with_password" and "update_without_password". The latter is different in that it will not update the password attribute. There is a note in my method to confirm it is only recommended for backend/admin-only use.

If there is already an alternative way to do this in Devise please let me know.

Kind regards

Ben