Sha256: 967f3619db39dbbd86caeb109f4f91bddb2581c212789516acedae2fd52aad16

Contents?: true

Size: 510 Bytes

Versions: 1

Compression:

Stored size: 510 Bytes

Contents

if defined?(Rails)
  if defined? Rails::Engine
    class Engine < Rails::Engine
      config.to_prepare do
        ActionView::Base.send :include, SwitchUserHelper
      end
    end
  else
    %w(controllers helpers).each do |dir|
      path = File.join(File.dirname(__FILE__), '..', 'app', dir)
      $LOAD_PATH << path
      ActiveSupport::Dependencies.load_paths << path
      ActiveSupport::Dependencies.load_once_paths.delete(path)
      ActionView::Base.send :include, SwitchUserHelper
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
switch_user-0.9.0 lib/switch_user/rails.rb