diff options
author | Michael Mair-Keimberger <m.mairkeimberger@gmail.com> | 2019-05-17 20:25:09 +0200 |
---|---|---|
committer | Michael Palimaka <kensington@gentoo.org> | 2019-05-19 10:41:06 +1000 |
commit | 6d20b7271981055346362eb8c3cca4197d2f4011 (patch) | |
tree | 4c13c542d1d03973ef609bf3abccb81c2de26961 /dev-ruby/database_cleaner | |
parent | app-doc/linkers-and-loaders: EAPI=7 update (diff) | |
download | gentoo-6d20b7271981055346362eb8c3cca4197d2f4011.tar.gz gentoo-6d20b7271981055346362eb8c3cca4197d2f4011.tar.bz2 gentoo-6d20b7271981055346362eb8c3cca4197d2f4011.zip |
dev-ruby/database_cleaner: remove unused patch(es)
Signed-off-by: Michael Mair-Keimberger <m.mairkeimberger@gmail.com>
Signed-off-by: Michael Palimaka <kensington@gentoo.org>
Diffstat (limited to 'dev-ruby/database_cleaner')
-rw-r--r-- | dev-ruby/database_cleaner/files/database_cleaner-1.6.2-table-quote.patch | 37 |
1 files changed, 0 insertions, 37 deletions
diff --git a/dev-ruby/database_cleaner/files/database_cleaner-1.6.2-table-quote.patch b/dev-ruby/database_cleaner/files/database_cleaner-1.6.2-table-quote.patch deleted file mode 100644 index 2ca8c9781247..000000000000 --- a/dev-ruby/database_cleaner/files/database_cleaner-1.6.2-table-quote.patch +++ /dev/null @@ -1,37 +0,0 @@ -From 94f3c412b154100e53b0800622a503ee56e39a6d Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Andreas=20B=C3=BChmann?= <dev@uuml.de> -Date: Sun, 27 Aug 2017 09:24:41 +0200 -Subject: [PATCH] Properly quote table names in table_stats_query - ---- - lib/database_cleaner/active_record/deletion.rb | 16 +++++++++------- - 1 file changed, 9 insertions(+), 7 deletions(-) - -diff --git a/lib/database_cleaner/active_record/deletion.rb b/lib/database_cleaner/active_record/deletion.rb -index 59a41c4..d172355 100644 ---- a/lib/database_cleaner/active_record/deletion.rb -+++ b/lib/database_cleaner/active_record/deletion.rb -@@ -66,14 +66,16 @@ def table_stats_query(connection, db_name) - if @cache_tables && !@table_stats_query.nil? - return @table_stats_query - else -- @table_stats_query = connection.select_values(<<-SQL).join(' UNION ') -- SELECT CONCAT('SELECT \"', table_name, '\" AS table_name, COUNT(*) AS exact_row_count FROM ', table_name) -- FROM -- INFORMATION_SCHEMA.TABLES -- WHERE -- table_schema = '#{db_name}' -- AND #{::DatabaseCleaner::ActiveRecord::Base.exclusion_condition('table_name')}; -+ tables = connection.select_values(<<-SQL) -+ SELECT table_name -+ FROM information_schema.tables -+ WHERE table_schema = '#{db_name}' -+ AND #{::DatabaseCleaner::ActiveRecord::Base.exclusion_condition('table_name')}; - SQL -+ queries = tables.map do |table| -+ "SELECT #{connection.quote(table)} AS table_name, COUNT(*) AS exact_row_count FROM #{connection.quote_table_name(table)}" -+ end -+ @table_stats_query = queries.join(' UNION ') - end - end - |