Skip to content

Commit

Permalink
Sort autoloads
Browse files Browse the repository at this point in the history
  • Loading branch information
rafaelfranca committed Nov 18, 2021
1 parent a97c7f5 commit 9a6669d
Showing 1 changed file with 24 additions and 30 deletions.
54 changes: 24 additions & 30 deletions activerecord/lib/active_record.rb
Expand Up @@ -38,23 +38,23 @@ module ActiveRecord

autoload :Base
autoload :Callbacks
autoload :Core
autoload :ConnectionHandling
autoload :Core
autoload :CounterCache
autoload :DynamicMatchers
autoload :DelegatedType
autoload :DestroyAssociationAsyncJob
autoload :DynamicMatchers
autoload :Encryption
autoload :Enum
autoload :InternalMetadata
autoload :Explain
autoload :Inheritance
autoload :Integration
autoload :InternalMetadata
autoload :Migration
autoload :Migrator, "active_record/migration"
autoload :ModelSchema
autoload :NestedAttributes
autoload :NoTouching
autoload :TouchLater
autoload :Persistence
autoload :QueryCache
autoload :Querying
Expand All @@ -68,34 +68,37 @@ module ActiveRecord
autoload :SchemaDumper
autoload :SchemaMigration
autoload :Scoping
autoload :SecureToken
autoload :Serialization
autoload :Store
autoload :SignedId
autoload :Store
autoload :Suppressor
autoload :TestDatabases
autoload :TestFixtures
autoload :Timestamp
autoload :TouchLater
autoload :Transactions
autoload :Translation
autoload :Validations
autoload :SecureToken
autoload :DestroyAssociationAsyncJob

eager_autoload do
autoload :StatementCache
autoload :ConnectionAdapters

autoload :Aggregations
autoload :AssociationRelation
autoload :Associations
autoload :AsynchronousQueriesTracker
autoload :AttributeAssignment
autoload :AttributeMethods
autoload :AutosaveAssociation
autoload :AsynchronousQueriesTracker

autoload :LegacyYamlAdapter

autoload :Relation
autoload :AssociationRelation
autoload :ConnectionAdapters
autoload :DisableJoinsAssociationRelation
autoload :FutureResult
autoload :LegacyYamlAdapter
autoload :NullRelation
autoload :Relation
autoload :Result
autoload :StatementCache
autoload :TableMetadata
autoload :Type

autoload_under "relation" do
autoload :QueryMethods
Expand All @@ -106,16 +109,11 @@ module ActiveRecord
autoload :Batches
autoload :Delegation
end

autoload :Result
autoload :FutureResult
autoload :TableMetadata
autoload :Type
end

module Coders
autoload :YAMLColumn, "active_record/coders/yaml_column"
autoload :JSON, "active_record/coders/json"
autoload :YAMLColumn, "active_record/coders/yaml_column"
end

module AttributeMethods
Expand All @@ -127,9 +125,9 @@ module AttributeMethods
autoload :PrimaryKey
autoload :Query
autoload :Read
autoload :Serialization
autoload :TimeZoneConversion
autoload :Write
autoload :Serialization
end
end

Expand All @@ -146,8 +144,8 @@ module Scoping
extend ActiveSupport::Autoload

eager_autoload do
autoload :Named
autoload :Default
autoload :Named
end
end

Expand All @@ -162,15 +160,11 @@ module Tasks
extend ActiveSupport::Autoload

autoload :DatabaseTasks
autoload :SQLiteDatabaseTasks, "active_record/tasks/sqlite_database_tasks"
autoload :MySQLDatabaseTasks, "active_record/tasks/mysql_database_tasks"
autoload :PostgreSQLDatabaseTasks,
"active_record/tasks/postgresql_database_tasks"
autoload :PostgreSQLDatabaseTasks, "active_record/tasks/postgresql_database_tasks"
autoload :SQLiteDatabaseTasks, "active_record/tasks/sqlite_database_tasks"
end

autoload :TestDatabases
autoload :TestFixtures

# Lazily load the schema cache. This option will load the schema cache
# when a connection is established rather than on boot. If set,
# +config.active_record.use_schema_cache_dump+ will be set to false.
Expand Down

0 comments on commit 9a6669d

Please sign in to comment.