From a49c7a1cd178b32b47f7342ee903e970222fbff1 Mon Sep 17 00:00:00 2001 From: Weston Ganger Date: Tue, 22 Jan 2019 10:48:03 -0800 Subject: [PATCH] Skip ApplicationRecord --- lib/active_record/annotate.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/active_record/annotate.rb b/lib/active_record/annotate.rb index 9dc3603..25ec275 100644 --- a/lib/active_record/annotate.rb +++ b/lib/active_record/annotate.rb @@ -45,6 +45,7 @@ def models klass = class_name_for(short_path) next unless klass < ActiveRecord::Base # collect only AR::Base descendants + next if klass.name == "ApplicationRecord" # skip ApplicationRecord models[klass.table_name] << [path, klass] end