Skip to content

Commit b7d9654

Browse files
authored
Merge pull request rails#50075 from kmcphillips/ar-adapter-class-nil-adapter
Do not attempt to resolve an `adapter_class` if no `adapter` is present
2 parents 550c5d2 + 5cd94d9 commit b7d9654

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

activerecord/lib/active_record/database_configurations/database_config.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ class DatabaseConfig # :nodoc:
1010

1111
def self.new(...)
1212
instance = super
13-
instance.adapter_class # Ensure resolution happens early
13+
instance.adapter_class if instance.adapter # Ensure resolution happens early
1414
instance
1515
end
1616

0 commit comments

Comments
 (0)