Merge pull request #7187 from luisramos0/uniq

[Rails 5.2] Relation#Uniq is deprecated, distinct is recommended instead
This commit is contained in:
Andy Brett
2021-03-23 20:52:47 -07:00
committed by GitHub

View File

@@ -173,7 +173,7 @@ module Spree
scope :in_distributors, lambda { |distributors|
with_order_cycles_outer.
where('(o_exchanges.incoming = ? AND o_exchanges.receiver_id IN (?))', false, distributors).
uniq
distinct
}
# Products supplied by a given enterprise or distributed via that enterprise through an OC