Fixed #3933 - Startup of Zammad does not synchronize the custom branding logo.

This commit is contained in:
Martin Edenhofer 2022-01-25 15:13:43 +01:00 committed by Dominik Klein
parent 273b46b810
commit a1af43d3e7

View file

@ -2,11 +2,14 @@
Rails.application.reloader.to_prepare do Rails.application.reloader.to_prepare do
next if !ActiveRecord::Base.connected? begin
# sync logo to fs / only if settings already exists # sync logo to fs / only if settings already exists
next if ActiveRecord::Base.connection.tables.exclude?('settings') next if ActiveRecord::Base.connection.tables.exclude?('settings')
next if Setting.column_names.exclude?('state_current') next if Setting.column_names.exclude?('state_current')
StaticAssets.sync StaticAssets.sync
rescue ::ActiveRecord::NoDatabaseError
Rails.logger.debug("Database doesn't exist. Skipping StaticAssets.sync")
end
end end