You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
educoder/app/controllers/users/passwords_controller.rb

15 lines
331 B

class Users::PasswordsController < Users::BaseAccountController
def update
Users::UpdatePasswordService.call(observed_user, update_params)
render_ok
rescue Users::UpdatePasswordService::Error => ex
render_error(ex.message)
end
private
def update_params
params.permit(:password, :old_password)
end
end