aboutsummaryrefslogtreecommitdiffstats
path: root/.rubocop.yml
diff options
context:
space:
mode:
authorGeorge Claghorn <george@basecamp.com>2018-07-07 17:04:47 -0400
committerGeorge Claghorn <george@basecamp.com>2018-07-07 17:09:31 -0400
commit03afddd2eb0fb56716a8a9caa4456807706ce791 (patch)
tree8382eba357d69f6d2acf776582c2113ed60c71c9 /.rubocop.yml
parent13c66d4626707fcc6c67ec6b197bb1e0be317b84 (diff)
downloadrails-03afddd2eb0fb56716a8a9caa4456807706ce791.tar.gz
rails-03afddd2eb0fb56716a8a9caa4456807706ce791.tar.bz2
rails-03afddd2eb0fb56716a8a9caa4456807706ce791.zip
Fix that models can clobber each others' attachment reflections
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.
Diffstat (limited to '.rubocop.yml')
0 files changed, 0 insertions, 0 deletions