Skip to content

Commit ec1c5ac

Browse files
authored
Merge pull request rails#55453 from jordanmoore753/add_skip_strict_loading_doc
docs: document when error raising is skipped for strict loading
2 parents 50390cf + 8a2fd9c commit ec1c5ac

File tree

1 file changed

+2
-0
lines changed
  • activerecord/lib/active_record

1 file changed

+2
-0
lines changed

activerecord/lib/active_record/core.rb

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -690,6 +690,8 @@ def strict_loading?
690690
# Sets the record to strict_loading mode. This will raise an error
691691
# if the record tries to lazily load an association.
692692
#
693+
# NOTE: Strict loading is disabled during validation in order to let the record validate its association.
694+
#
693695
# user = User.first
694696
# user.strict_loading! # => true
695697
# user.address.city

0 commit comments

Comments
 (0)