debian-mirror-gitlab/app/controllers/profiles/u2f_registrations_controller.rb
2018-12-05 23:21:45 +05:30

9 lines
335 B
Ruby

# frozen_string_literal: true
class Profiles::U2fRegistrationsController < Profiles::ApplicationController
def destroy
u2f_registration = current_user.u2f_registrations.find(params[:id])
u2f_registration.destroy
redirect_to profile_two_factor_auth_path, status: 302, notice: "Successfully deleted U2F device."
end
end