From 364fa2603cf615168a002b5849eb335fb423707c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Javi=20Mart=C3=ADn?= Date: Mon, 15 Apr 2024 15:12:22 +0200 Subject: [PATCH] Raise exceptions when assigning to attr_readonly attributes Since we don't use attr_readonly, this option doesn't really affect us. So we're just using the new default value. --- config/initializers/new_framework_defaults_7_1.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/config/initializers/new_framework_defaults_7_1.rb b/config/initializers/new_framework_defaults_7_1.rb index b88647b52..473525c47 100644 --- a/config/initializers/new_framework_defaults_7_1.rb +++ b/config/initializers/new_framework_defaults_7_1.rb @@ -158,7 +158,7 @@ end # behavior would allow assignment but silently not persist changes to the # database. #++ -# Rails.application.config.active_record.raise_on_assign_to_attr_readonly = true +Rails.application.config.active_record.raise_on_assign_to_attr_readonly = true ### # Enable validating only parent-related columns for presence when the parent is mandatory.