Sha256: 72750c002f6383a94671ee414b6c16679b17558248ecf70eadcc42dba928ce45

Contents?: true

Size: 795 Bytes

Versions: 12

Compression:

Stored size: 795 Bytes

Contents

module Wiselinks
  module Rails
    class Engine < ::Rails::Engine
      initializer 'wiselinks.register_logger' do
        Wiselinks.options[:logger] = ::Rails.logger
      end

      initializer "wiselinks.register_extensions"  do
        ActionDispatch::Request.send :include, Request
        ActionController::Base.send :include, ControllerMethods
        ActionController::Base.send :include, Rendering
        ActionView::Base.send :include, Helpers
      end

      initializer "wiselinks.register_assets_digest"  do
        if ::Rails.application.config.assets.digest && ::Rails.application.config.assets.digests.present?
          Wiselinks.options[:assets_digest] ||= Digest::MD5.hexdigest(::Rails.application.config.assets.digests.values.join)
        end
      end
    end
  end
end

Version data entries

12 entries across 12 versions & 2 rubygems

Version Path
wiselinks-artirix-1.3.0 lib/wiselinks/rails.rb
wiselinks-1.2.1 lib/wiselinks/rails.rb
wiselinks-1.2.0 lib/wiselinks/rails.rb
wiselinks-1.1.4 lib/wiselinks/rails.rb
wiselinks-1.1.2 lib/wiselinks/rails.rb
wiselinks-1.1.1 lib/wiselinks/rails.rb
wiselinks-1.1.0 lib/wiselinks/rails.rb
wiselinks-1.0.0 lib/wiselinks/rails.rb
wiselinks-0.7.3 lib/wiselinks/rails.rb
wiselinks-0.7.2 lib/wiselinks/rails.rb
wiselinks-0.7.1 lib/wiselinks/rails.rb
wiselinks-0.7.0 lib/wiselinks/rails.rb