aboutsummaryrefslogtreecommitdiffstats
path: root/activestorage/lib/active_storage/reflection.rb
Commit message (Collapse)AuthorAgeFilesLines
* Fix that models can clobber each others' attachment reflectionsGeorge Claghorn2018-07-071-2/+2
| | | | | | | | | | | | | | Consider the following model definitions: class User < ApplicationRecord has_one_attached :avatar end class Group < ApplicationRecord has_one_attached :avatar end If you attempt to reflect on the User model's avatar attachment via User.reflect_on_attachment, you could receive a reflection for the Group model's avatar attachment. Fix this by ensuring that each model class uses its own Hash object to track attachment reflections.
* Ensure reflection_class_for is privateKevin Deisz2018-05-311-12/+13
|
* Move ActiveStorage reflection logic entirely into ActiveStorageKevin Deisz2018-05-311-0/+63