From 3646822ec3edcfda8582759cd0c7ad4787be8fd6 Mon Sep 17 00:00:00 2001 From: xxqfamous Date: Thu, 25 May 2023 18:35:19 +0800 Subject: [PATCH] =?UTF-8?q?docker=E9=83=A8=E7=BD=B2=E6=95=B4=E7=90=86=20ss?= =?UTF-8?q?l=E7=A6=81=E7=94=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lib/tasks/sync_table_structure.rake | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/tasks/sync_table_structure.rake b/lib/tasks/sync_table_structure.rake index 27c27d6f..e0eb24d7 100644 --- a/lib/tasks/sync_table_structure.rake +++ b/lib/tasks/sync_table_structure.rake @@ -7,7 +7,7 @@ namespace :sync_table_structure do database_config = Rails.configuration.database_configuration table_count = ActiveRecord::Base.connection.query_value("SELECT count(*) FROM information_schema.`TABLES` where TABLE_SCHEMA='#{database_config[Rails.env]["database"]}'") - return if table_count.to_i > 10 + next if table_count.to_i > 10 database = database_config[Rails.env]["database"] database_username = database_config[Rails.env]["username"]