Sha256: 0479294abbc1ec857fb61a52341649309fa3b5ae89ba3300c089d24a7f23de01
Contents?: true
Size: 570 Bytes
Versions: 2
Compression:
Stored size: 570 Bytes
Contents
module MicroSessions if defined?(Rails::Railtie) class Railtie < Rails::Railtie initializer "micro_sessions.insert" do ActiveSupport.on_load(:action_controller) do MicroSessions::Railtie.insert end end end end class Railtie def self.insert ActionController::Base.send(:include, MicroSessions::Controller) ActionView::Helpers::UrlHelper.send(:include, MicroSessions::Helpers::UrlHelper) ActionView::Helpers::FormTagHelper.send(:include, MicroSessions::Helpers::FormTagHelper) end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
micro_sessions-0.1.1 | lib/micro_sessions/railtie.rb |
micro_sessions-0.1.0 | lib/micro_sessions/railtie.rb |