Permalink
Browse files

build_arel should respect uniq_value

  • Loading branch information...
1 parent 6eaf342 commit cf95bad3c7794dc13721ec034a358b4cc7f0d561 @aepstein committed Jan 21, 2012
Showing with 2 additions and 1 deletion.
  1. +2 −1 lib/squeel/adapters/active_record/relation_extensions.rb
@@ -102,7 +102,8 @@ def build_arel
arel.order(*order) unless order.empty?
build_select(arel, attribute_viz.accept(@select_values.uniq))
-
+
+ arel.distinct(@uniq_value)
arel.from(@from_value) if @from_value
arel.lock(@lock_value) if @lock_value

0 comments on commit cf95bad

Please sign in to comment.