Remove deprecated ActiveRecord::ConnectionAdapters::SchemaCache.load_from
This commit is contained in:
parent
9391f0a0e8
commit
5667de1aca
@ -1,3 +1,7 @@
|
||||
* Remove deprecated `ActiveRecord::ConnectionAdapters::SchemaCache.load_from`.
|
||||
|
||||
*Rafael Mendonça França*
|
||||
|
||||
* Remove deprecated `#all_foreign_keys_valid?` from database adapters.
|
||||
|
||||
*Rafael Mendonça França*
|
||||
|
@ -225,18 +225,6 @@ def dump_to(filename)
|
||||
|
||||
# = Active Record Connection Adapters Schema Cache
|
||||
class SchemaCache
|
||||
class << self
|
||||
def new(connection)
|
||||
BoundSchemaReflection.new(SchemaReflection.new(nil), connection.pool)
|
||||
end
|
||||
deprecate new: "use ActiveRecord::ConnectionAdapters::SchemaReflection instead", deprecator: ActiveRecord.deprecator
|
||||
|
||||
def load_from(filename) # :nodoc:
|
||||
BoundSchemaReflection.new(SchemaReflection.new(filename), nil)
|
||||
end
|
||||
deprecate load_from: "use ActiveRecord::ConnectionAdapters::SchemaReflection instead", deprecator: ActiveRecord.deprecator
|
||||
end
|
||||
|
||||
def self._load_from(filename) # :nodoc:
|
||||
return unless File.file?(filename)
|
||||
|
||||
@ -264,7 +252,7 @@ def self.read(filename, &block)
|
||||
end
|
||||
private_class_method :read
|
||||
|
||||
def initialize
|
||||
def initialize # :nodoc:
|
||||
@columns = {}
|
||||
@columns_hash = {}
|
||||
@primary_keys = {}
|
||||
@ -290,7 +278,7 @@ def encode_with(coder) # :nodoc:
|
||||
coder["version"] = @version
|
||||
end
|
||||
|
||||
def init_with(coder)
|
||||
def init_with(coder) # :nodoc:
|
||||
@columns = coder["columns"]
|
||||
@columns_hash = coder["columns_hash"]
|
||||
@primary_keys = coder["primary_keys"]
|
||||
|
@ -144,6 +144,8 @@ Please refer to the [Changelog][active-record] for detailed changes.
|
||||
|
||||
* Remove deprecated `#all_foreign_keys_valid?` from database adapters.
|
||||
|
||||
* Remove deprecated `ActiveRecord::ConnectionAdapters::SchemaCache.load_from`.
|
||||
|
||||
### Deprecations
|
||||
|
||||
* Deprecate `Rails.application.config.active_record.allow_deprecated_singular_associations_name`
|
||||
|
Loading…
Reference in New Issue
Block a user