about summary refs log tree commit diff
path: root/app/controllers/well_known/keybase_proof_config_controller.rb
blob: c78683a8d5d5094eef67c86d4255289f2e55ae8f (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
# frozen_string_literal: true

module WellKnown
  class KeybaseProofConfigController < ActionController::Base
    before_action :check_enabled

    def show
      render json: {}, serializer: ProofProvider::Keybase::ConfigSerializer
    end

    private

    def check_enabled
      head 404 unless Setting.enable_keybase
    end
  end
end