<commit_before>Spree::Variant.class_eval do
  has_many :variant_images, -> { order(:position) }, class_name: '::Spree::VariantImage'
  has_many :images_for_variant, through: :variant_images, source: :image
  has_many :images, -> { order(:position) }, as: :viewable

  def images
    images_for_variant
  end
end<commit_msg>Clean up variant images association<commit_after>Spree::Variant.class_eval do
  has_many :variant_images, -> { order(:position) }, class_name: '::Spree::VariantImage'
  has_many :images, through: :variant_images, source: :image
end
{'fraction_non_alphanumeric': 0.1299638989169675, 'fraction_numerical': 0.0, 'mean_word_length': 6.602739726027397, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 6, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2632530', 'n_tokens_mistral': 178, 'n_tokens_neox': 176, 'n_words': 40}