Sha256: 58b7eef3a93c0d9950729516dd6732490477c8bcfa39e5ed00ec277a6f29fec9
Contents?: true
Size: 652 Bytes
Versions: 1
Compression:
Stored size: 652 Bytes
Contents
module StackableFlash class Railtie < Rails::Railtie # Only support Rails 3+? #ActiveSupport.on_load(:action_controller) do # ActiveSupport.on_load(:after_initialize) do # ActionDispatch::Flash::FlashHash.send :include, StackableFlash::StackLayer # end #end config.after_initialize do require 'action_pack/version' base = if ActionPack::VERSION::MAJOR >= 3 require 'action_dispatch' ActionDispatch::Flash::FlashHash else require 'action_controller' ActionController::Flash::FlashHash end base.send :prepend, StackableFlash::StackLayer end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
stackable_flash-0.1.1 | lib/stackable_flash/railtie.rb |