mirror of
https://github.com/opf/openproject.git
synced 2026-06-13 19:20:00 +00:00
Allow details table to be missing for inside migration calls
This commit is contained in:
@@ -263,6 +263,9 @@ module HasDetailsTable
|
||||
|
||||
def finalize_detail_delegation!(detail_class, foreign_key)
|
||||
return if @_detail_delegation_set_up
|
||||
# The detail table may not yet exist during early migrations on a fresh
|
||||
# database. Skip — the next instance will retry once the table is there.
|
||||
return unless ActiveRecord::Base.connected? && detail_class.table_exists?
|
||||
|
||||
@_detail_delegation_set_up = true
|
||||
|
||||
|
||||
Reference in New Issue
Block a user