GitLab steht aufgrund eines wichtigen Updates heute, zwischen 18:00 und 19:00 Uhr, nicht zur Verfügung.

Commit cd22da3e authored by Rémy Coutable's avatar Rémy Coutable

Fix preventing migration from crashing in very specific cases

See for details
parent 8b3285bf
......@@ -39,6 +39,13 @@ def connect_to_db?
use_db && &&
# The following condition is important: if a migrations adds a
# column to the application_settings table and a validation in
# the ApplicationSetting uses this new column we might end-up in
# a vicious circle where migration crash before being done.
# See for
# a thorough explanation.
!ActiveRecord::Migrator.needs_migration? &&
rescue ActiveRecord::NoDatabaseError
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment