Sha256: 54498397729a5c601f9e2c191461188d75d5885e97f02546eae5a5d210564c53

Contents?: true

Size: 537 Bytes

Versions: 15

Compression:

Stored size: 537 Bytes

Contents

module OpenStax
  module Api
    module DoorkeeperApplicationIncludes
      # Add some fields to Doorkeeper::Application
      def is_human?
        false
      end
      
      def is_application?
        true
      end
      
      def is_admin?
        false
      end
    end
  end
end

# This needs to run after the orm is selected in the doorkeeper initializer
OpenStax::Api::Engine.config.after_initialize do
  Doorkeeper::Application.send :include,
                               OpenStax::Api::DoorkeeperApplicationIncludes
end

Version data entries

15 entries across 15 versions & 1 rubygems

Version Path
openstax_api-3.0.1 lib/openstax/api/doorkeeper_application_includes.rb
openstax_api-3.0.0 lib/openstax/api/doorkeeper_application_includes.rb
openstax_api-2.5.1 lib/openstax/api/doorkeeper_application_includes.rb
openstax_api-2.5.0 lib/openstax/api/doorkeeper_application_includes.rb
openstax_api-2.4.0 lib/openstax/api/doorkeeper_application_includes.rb
openstax_api-2.3.1 lib/openstax/api/doorkeeper_application_includes.rb
openstax_api-2.3.0 lib/openstax/api/doorkeeper_application_includes.rb
openstax_api-2.2.4 lib/openstax/api/doorkeeper_application_includes.rb
openstax_api-2.2.3 lib/openstax/api/doorkeeper_application_includes.rb
openstax_api-2.2.2 lib/openstax/api/doorkeeper_application_includes.rb
openstax_api-2.2.1 lib/openstax/api/doorkeeper_application_includes.rb
openstax_api-2.2.0 lib/openstax/api/doorkeeper_application_includes.rb
openstax_api-2.1.1 lib/openstax/api/doorkeeper_application_includes.rb
openstax_api-2.1.0 lib/openstax/api/doorkeeper_application_includes.rb
openstax_api-2.0.0 lib/openstax/api/doorkeeper_application_includes.rb