Sha256: 029f74b1969bbbf990eb71eaf0df2bfd36258ba08c614bd6cd95181062ae7be3

Contents?: true

Size: 500 Bytes

Versions: 11

Compression:

Stored size: 500 Bytes

Contents

module RailsAdminSettings
  class Engine < ::Rails::Engine
    rake_tasks do
      require File.expand_path('../tasks', __FILE__)
    end

    initializer 'RailsAdminSettings Install after_action' do |app|
      require File.dirname(__FILE__) + '/../../app/models/rails_admin_settings/setting.rb'

      if defined?(ActionController) and defined?(ActionController::Base)
        ActionController::Base.class_eval do
          after_action { Settings.unload! }
        end
      end
    end
  end
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
rails_admin_settings-1.7.0 lib/rails_admin_settings/engine.rb
rails_admin_settings-1.6.0 lib/rails_admin_settings/engine.rb
rails_admin_settings-1.5.1 lib/rails_admin_settings/engine.rb
rails_admin_settings-1.5.0 lib/rails_admin_settings/engine.rb
rails_admin_settings-1.4.2 lib/rails_admin_settings/engine.rb
rails_admin_settings-1.4.1 lib/rails_admin_settings/engine.rb
rails_admin_settings-1.4.0 lib/rails_admin_settings/engine.rb
rails_admin_settings-1.3.2 lib/rails_admin_settings/engine.rb
rails_admin_settings-1.3.1 lib/rails_admin_settings/engine.rb
rails_admin_settings-1.3.0 lib/rails_admin_settings/engine.rb
rails_admin_settings-1.2.1 lib/rails_admin_settings/engine.rb