mirror of
https://github.com/discourse/discourse.git
synced 2025-02-16 18:24:52 -06:00
FIX: restore in development mode connects to the wrong database
This commit is contained in:
parent
06c9e79984
commit
3939b9ec7d
@ -100,7 +100,7 @@ module BackupRestore
|
||||
DatabaseConfiguration = Struct.new(:host, :port, :username, :password, :database)
|
||||
|
||||
def self.database_configuration
|
||||
config = Rails.env.production? ? ActiveRecord::Base.connection_pool.spec.config : Rails.configuration.database_configuration[Rails.env]
|
||||
config = ActiveRecord::Base.connection_pool.spec.config
|
||||
config = config.with_indifferent_access
|
||||
|
||||
DatabaseConfiguration.new(
|
||||
|
Loading…
Reference in New Issue
Block a user