From 1a5d2debc27d91d1cabfa43082fbc6181829dff8 Mon Sep 17 00:00:00 2001 From: r7kamura Date: Mon, 22 Jan 2024 06:19:41 +0900 Subject: [PATCH] Remove `object_id` from `Rails/DangerousColumnNames` targets --- changelog/change_remove_object_id_from.md | 1 + lib/rubocop/cop/rails/dangerous_column_names.rb | 3 +-- 2 files changed, 2 insertions(+), 2 deletions(-) create mode 100644 changelog/change_remove_object_id_from.md diff --git a/changelog/change_remove_object_id_from.md b/changelog/change_remove_object_id_from.md new file mode 100644 index 0000000000..17edfb530c --- /dev/null +++ b/changelog/change_remove_object_id_from.md @@ -0,0 +1 @@ +* [#1231](https://github.com/rubocop/rubocop-rails/pull/1231): Remove `object_id` from `Rails/DangerousColumnNames` targets. ([@r7kamura][]) diff --git a/lib/rubocop/cop/rails/dangerous_column_names.rb b/lib/rubocop/cop/rails/dangerous_column_names.rb index a1c1bcc1bb..3961e3b40b 100644 --- a/lib/rubocop/cop/rails/dangerous_column_names.rb +++ b/lib/rubocop/cop/rails/dangerous_column_names.rb @@ -31,7 +31,7 @@ class DangerousColumnNames < Base # rubocop:disable Metrics/ClassLength time ].to_set.freeze - # Generated from `ActiveRecord::AttributeMethods.dangerous_attribute_methods` on activerecord 7.1.0. + # Generated from `ActiveRecord::AttributeMethods.dangerous_attribute_methods` on activerecord 7.1.3. # rubocop:disable Metrics/CollectionLiteralLength DANGEROUS_COLUMN_NAMES = %w[ __callbacks @@ -290,7 +290,6 @@ class DangerousColumnNames < Base # rubocop:disable Metrics/ClassLength new_record no_touching normalize_reflection_attribute - object_id partial_inserts partial_updates perform_validations