Project

General

Profile

« Previous | Next » 

Revision ff1e9ffc

Added by Dominic Cleal over 6 years ago

Fixes #20950 - Use 'distinct' in AR finders

View differences:

app/models/environment.rb
before_destroy EnsureNotUsedBy.new(:hosts, :hostgroups)
has_many :environment_classes, :dependent => :destroy
has_many :puppetclasses, -> { uniq }, :through => :environment_classes
has_many :puppetclasses, -> { distinct }, :through => :environment_classes
has_many_hosts
has_many :hostgroups

Also available in: Unified diff