-
Joé Dupuis authored
PR #48606 introduced a regression preventing the creation of a chain of models using a has_one through association when strict_loading is activated. The association relies on the initial stale_state being `nil` to skip loading the target. https://github.com/gmcgibbon/rails/blob/755c13f167af4fddc6960ed3768ed7e178a2395a/activerecord/lib/active_record/associations/association.rb#L175 PR #48606 initializes the stale_state to `[nil]` https://github.com/rails/rails/pull/48606/files#diff-39c3da3c5f3fbff01b0a32d3b7ec613fda6bc6225fdbe2629134d91babe37786R84-R86 This change converts the `[nil]` state back to `nil`.
Joé Dupuis authoredPR #48606 introduced a regression preventing the creation of a chain of models using a has_one through association when strict_loading is activated. The association relies on the initial stale_state being `nil` to skip loading the target. https://github.com/gmcgibbon/rails/blob/755c13f167af4fddc6960ed3768ed7e178a2395a/activerecord/lib/active_record/associations/association.rb#L175 PR #48606 initializes the stale_state to `[nil]` https://github.com/rails/rails/pull/48606/files#diff-39c3da3c5f3fbff01b0a32d3b7ec613fda6bc6225fdbe2629134d91babe37786R84-R86 This change converts the `[nil]` state back to `nil`.
Loading