Module: ActiveSupport::Dependencies

Defined in:
lib/active_support_decorators/dependencies_patch.rb

Instance Method Summary collapse

Instance Method Details

#require_or_load(file_name, const_path = nil) ⇒ Object



7
8
9
10
11
12
13
14
15
16
17
# File 'lib/active_support_decorators/dependencies_patch.rb', line 7

def require_or_load(file_name, const_path = nil)
  order = ActiveSupportDecorators.load_path_order(file_name, const_path)

  if ActiveSupportDecorators.debug && order.size > 1
    Rails.try(:logger).try(:debug, "ActiveSupportDecorators: Loading files in order #{order.join(', ')}.")
  end

  order.each do |path|
    require_or_load_without_multiple(path, const_path)
  end
end

#require_or_load_without_multipleObject



5
# File 'lib/active_support_decorators/dependencies_patch.rb', line 5

alias_method :require_or_load_without_multiple, :require_or_load