DEV: avoid loading module in production
This commit is contained in:
parent
6b192d29fa
commit
de5f2d3308
|
@ -1,12 +1,11 @@
|
||||||
# frozen_string_literal: true
|
# frozen_string_literal: true
|
||||||
|
|
||||||
require_dependency 'migration/safe_migrate'
|
|
||||||
|
|
||||||
# We do not run this in production cause it is intrusive and has
|
# We do not run this in production cause it is intrusive and has
|
||||||
# potential to break stuff, it also breaks under concurrent use
|
# potential to break stuff, it also breaks under concurrent use
|
||||||
# which rake:multisite_migrate uses
|
# which rake:multisite_migrate uses
|
||||||
#
|
#
|
||||||
# The protection is only needed in Dev and Test
|
# The protection is only needed in Dev and Test
|
||||||
if ENV['RAILS_ENV'] != "production"
|
if ENV['RAILS_ENV'] != "production"
|
||||||
|
require_dependency 'migration/safe_migrate'
|
||||||
Migration::SafeMigrate.patch_active_record!
|
Migration::SafeMigrate.patch_active_record!
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue