aboutsummaryrefslogblamecommitdiffstats
path: root/railties/lib/rails/deprecation.rb
blob: 155166a113dc0c1764140b2684e3d211a16b57e7 (plain) (tree)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16















                                                                        
        
require "active_support/string_inquirer"
require "active_support/deprecation"

RAILS_ROOT = (Class.new(ActiveSupport::Deprecation::DeprecationProxy) do
  def target
    Rails.root
  end

  def replace(val)
    puts OMG
  end

  def warn(callstack, called, args)
    msg = "RAILS_ROOT is deprecated! Use Rails.root instead."
    ActiveSupport::Deprecation.warn(msg, callstack)
  end
end).new