method
new
v7.1.3.2 -
Show latest stable
-
0 notes -
Class: ActiveSupport::Deprecation::DeprecatedConstantProxy
new(old_const, new_const, deprecator = nil, message: "#{old_const} is deprecated! Use #{new_const} instead.")
public
Hide source
# File activesupport/lib/active_support/deprecation/proxy_wrappers.rb, line 130 def initialize(old_const, new_const, deprecator = nil, message: "#{old_const} is deprecated! Use #{new_const} instead.") Kernel.require "active_support/inflector/methods" @old_const = old_const @new_const = new_const ActiveSupport.deprecator.warn("DeprecatedConstantProxy without a deprecator is deprecated") unless deprecator @deprecator = deprecator || ActiveSupport::Deprecation._instance @message = message end