diff options
author | Zachary Scott <e@zzak.io> | 2014-11-22 17:43:12 -0800 |
---|---|---|
committer | Zachary Scott <e@zzak.io> | 2014-11-22 17:43:12 -0800 |
commit | e7bf741af9c1e3c38a751340f18a461a6b16f8bd (patch) | |
tree | 265f9ac00986107486c16bd9809a420085e91910 | |
parent | 6cd9e2bd29b26e1ea781fafce18614217b7adf7b (diff) | |
parent | 31b3069615529eabc42cc5bee1cd76e52bd1560b (diff) | |
download | rails-e7bf741af9c1e3c38a751340f18a461a6b16f8bd.tar.gz rails-e7bf741af9c1e3c38a751340f18a461a6b16f8bd.tar.bz2 rails-e7bf741af9c1e3c38a751340f18a461a6b16f8bd.zip |
Merge pull request #17718 from arthurnn/fixes_16928
Fixes 16928, improve reflections public API doc [ci skip]
-rw-r--r-- | activerecord/CHANGELOG.md | 6 | ||||
-rw-r--r-- | activerecord/lib/active_record/reflection.rb | 2 |
2 files changed, 7 insertions, 1 deletions
diff --git a/activerecord/CHANGELOG.md b/activerecord/CHANGELOG.md index 16f776df58..a4de332d4c 100644 --- a/activerecord/CHANGELOG.md +++ b/activerecord/CHANGELOG.md @@ -1,3 +1,9 @@ +* Change `reflections` public api to return the keys as String objects. + + Fixes #16928. + + *arthurnn* + * Renaming a table in pg also renames the primary key index. Fixes #12856 diff --git a/activerecord/lib/active_record/reflection.rb b/activerecord/lib/active_record/reflection.rb index f4a351b092..4219632596 100644 --- a/activerecord/lib/active_record/reflection.rb +++ b/activerecord/lib/active_record/reflection.rb @@ -63,7 +63,7 @@ module ActiveRecord # Returns a Hash of name of the reflection as the key and a AssociationReflection as the value. # - # Account.reflections # => {balance: AggregateReflection} + # Account.reflections # => {"balance" => AggregateReflection} # # @api public def reflections |