From 0e656ff213d11b0d416927763c284fa98f91aa5b Mon Sep 17 00:00:00 2001 From: Guo Xiang Tan Date: Thu, 17 Aug 2017 19:27:35 +0900 Subject: [PATCH] FIX: Can't reset AR schema cache due to versions table. --- lib/discourse.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/discourse.rb b/lib/discourse.rb index f267534b2b9..c2aa10a0eac 100644 --- a/lib/discourse.rb +++ b/lib/discourse.rb @@ -447,7 +447,7 @@ module Discourse def self.reset_active_record_cache ActiveRecord::Base.connection.query_cache.clear - (ActiveRecord::Base.connection.tables - %w[schema_migrations]).each do |table| + (ActiveRecord::Base.connection.tables - %w[schema_migrations versions]).each do |table| table.classify.constantize.reset_column_information rescue nil end nil