You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: users_controller.rb
    path of file: ./repos/discourse/app/controllers/admin
    
    the code of the file until where you have to start completion: # frozen_string_literal: true

class Admin::UsersController < Admin::StaffController
  MAX_SIMILAR_USERS = 10

  before_action :fetch_user,
                only: %i[
                  suspend
                  un
    
  def deactivate
    guardian.ensure_can_deactivate!(@user)
    @user.deactivate(current_user)
    StaffActionLogger.new(current_user).log_user_deactivate(
      @user,
      I18n.t("user.deactivated_by_staff"),
      params.slice(:context),
    )
    refresh_browser @user
    render json: success_json
  end