Commit bdbc4e13

mo k <mo@mokhan.ca>
2013-02-07 01:41:47
show unique creations
1 parent 2045def
Changed files (1)
app
app/services/queries/find_all_creations_query.rb
@@ -11,7 +11,7 @@ class FindAllCreationsQuery
   private
 
   def find_creations
-    Creation.joins(:photos).where(:is_restricted => false)
+    Creation.joins(:photos).where(:is_restricted => false).uniq
     #Creation.all.select do |creation|
       #creation.published? && creation.is_safe_for_children?
     #end