Match `config.load_defaults` Version to Rails Version by aaronskiba · Pull Request #3496 · DMPRoadmap/roadmap

added 2 commits

March 26, 2025 15:42
- Added explicit `coder: YAML` to `serialize` calls to conform with Rails 7.1 changes
  - (Rather than explicitly adding this, `config.active_record.default_column_serializer = YAML` could've been added to `config/application.rb` to restore the pre-Rails 7.1 behaviour)
- Retained `type:` where specified to enforce the expected type of deserialized objects.

@aaronskiba

@aaronskiba aaronskiba changed the title Aaron/config.load defaults 7.1 Match config.load_defaults Version to Rails Version

Mar 27, 2025

aaronskiba

The `serialize :prefs, type: Hash` line in the `User` model was redundant since the `prefs` column does not exist in the `users` table. User preferences are handled via the `Pref` model, which serializes its `settings` column as a JSON hash.

This change aligns with the update to store preferences in a separate model, as introduced in the following commit: 0405973

@aaronskiba

@aaronskiba aaronskiba deleted the aaron/config.load_defaults-7.1 branch

April 10, 2025 15:24