aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/lib/active_record/associations/join_dependency.rb
diff options
context:
space:
mode:
authorJames Wen <jrw2175@columbia.edu>2016-01-28 00:41:26 -0500
committerJames Wen <jrw2175@columbia.edu>2016-01-28 00:41:26 -0500
commit867a9cbbb818bb4f0d3990403c554a632f367944 (patch)
tree42cc8bf3c4c1283caa897f770c7d825a306ecae7 /activerecord/lib/active_record/associations/join_dependency.rb
parent1ac3fb9f06f57840311cb9f04cd6887d2ffde479 (diff)
downloadrails-867a9cbbb818bb4f0d3990403c554a632f367944.tar.gz
rails-867a9cbbb818bb4f0d3990403c554a632f367944.tar.bz2
rails-867a9cbbb818bb4f0d3990403c554a632f367944.zip
Improve clarity of error message for missing includes and eager_load
relations
Diffstat (limited to 'activerecord/lib/active_record/associations/join_dependency.rb')
-rw-r--r--activerecord/lib/active_record/associations/join_dependency.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/activerecord/lib/active_record/associations/join_dependency.rb b/activerecord/lib/active_record/associations/join_dependency.rb
index 0e4e951269..b94feeff12 100644
--- a/activerecord/lib/active_record/associations/join_dependency.rb
+++ b/activerecord/lib/active_record/associations/join_dependency.rb
@@ -228,7 +228,7 @@ module ActiveRecord
def find_reflection(klass, name)
klass._reflect_on_association(name) or
- raise ConfigurationError, "Association named '#{ name }' was not found on #{ klass.name }; perhaps you misspelled it?"
+ raise ConfigurationError, "Can't join '#{ klass.name }' to association named '#{ name }'; perhaps you misspelled it?"
end
def build(associations, base_klass)