Sha256: 2bd1ce85864e5bf0760def47b8f658111572dbe7e93fe1f869c3457610e4a356

Contents?: true

Size: 721 Bytes

Versions: 1

Compression:

Stored size: 721 Bytes

Contents

require "doorkeeper_hub/version"
require 'doorkeeper_hub/configurator'
require "doorkeeper_hub/saml"
require "doorkeeper_hub/helpers"
require 'doorkeeper_hub/engine' if defined?(::Rails) && Rails::VERSION::MAJOR > 4

module DoorkeeperHub
  def self.config
    @config ||= DoorkeeperHub::Configurator.new
  end

  def self.configure
    yield config
  end

  def self.devise_routes_scope
    user_model.to_s.tableize.to_sym
  end

  def self.devise_scope
    user_model.to_s.underscore.to_sym
  end

  def self.user_model
    config.user_model
  end

  def self.token_name
    config.doorkeeper_token_name
  end

  def self.token_param
    :doorkeeper_token
  end

  def self.client_mode?
    config.client_mode
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
doorkeeper_hub-0.2.5 lib/doorkeeper_hub.rb