Sha256: 9239253b497f9c023f5012d9cd5f2f27e8bee0acca3d2daf6cb97e34fc4113a1

Contents?: true

Size: 653 Bytes

Versions: 11

Compression:

Stored size: 653 Bytes

Contents

require "rack/oauth2/server"
require "rack/oauth2/rails"
require "rails"

module Rack
  module OAuth2
    class Server
      # Rails 3.x integration.
      class Railtie < ::Rails::Railtie # :nodoc:
        config.oauth = Server.options

        initializer "rack-oauth2-server" do |app|
          app.middleware.use ::Rack::OAuth2::Server, app.config.oauth
          config.oauth.logger ||= ::Rails.logger
          class ::ActionController::Base
            helper ::Rack::OAuth2::Rails::Helpers
            include ::Rack::OAuth2::Rails::Helpers
            extend ::Rack::OAuth2::Rails::Filters
          end
        end
      end
    end
  end
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
rack-oauth2-server-2.8.1 lib/rack/oauth2/server/railtie.rb
rack-oauth2-server-2.8.0 lib/rack/oauth2/server/railtie.rb
rack-oauth2-server-2.7.0 lib/rack/oauth2/server/railtie.rb
rack-oauth2-server-2.6.1 lib/rack/oauth2/server/railtie.rb
rack-oauth2-server-2.6.0 lib/rack/oauth2/server/railtie.rb
rack-oauth2-server-2.5.1 lib/rack/oauth2/server/railtie.rb
rack-oauth2-server-2.5.0 lib/rack/oauth2/server/railtie.rb
rack-oauth2-server-2.4.2 lib/rack/oauth2/server/railtie.rb
rack-oauth2-server-2.4.1 lib/rack/oauth2/server/railtie.rb
rack-oauth2-server-2.4.0 lib/rack/oauth2/server/railtie.rb
rack-oauth2-server-2.3.0 lib/rack/oauth2/server/railtie.rb