From 495024021e844e9e99f4e5fa505ea05a90d4cd34 Mon Sep 17 00:00:00 2001 From: Alexander Meindl Date: Wed, 13 Mar 2019 08:13:24 +0100 Subject: [PATCH] check database connection #40 --- init.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/init.rb b/init.rb index 4e7fb949..fc78d549 100644 --- a/init.rb +++ b/init.rb @@ -38,7 +38,7 @@ Redmine::Plugin.register :additionals do RedCloth3::ALLOWED_TAGS << 'div' end -if ActiveRecord::Base.connection.table_exists?(:settings) +if ActiveRecord::Base.connection.active? && ActiveRecord::Base.connection.table_exists?(:settings) Rails.configuration.to_prepare do Additionals.setup end