resets_controller.rb 311 B

1234567891011121314
  1. # frozen_string_literal: true
  2. module Admin
  3. class ResetsController < BaseController
  4. before_action :set_user
  5. def create
  6. authorize @user, :reset_password?
  7. @user.reset_password!
  8. log_action :reset_password, @user
  9. redirect_to admin_account_path(@user.account_id)
  10. end
  11. end
  12. end