Skip to content
Extraits de code Groupes Projets
Valider 805346c7 rédigé par danielgrippi's avatar danielgrippi
Parcourir les fichiers

use select distinct as opposed to group by

parent 161d9d52
Branches
Étiquettes
Aucune requête de fusion associée trouvée
......@@ -38,7 +38,7 @@ class StatusMessage < Post
}
scope :commented_by, lambda { |person|
joins(:comments).where(:comments => {:author_id => person.id}).group("posts.id")
joins(:comments).where(:comments => {:author_id => person.id}).select("DISTINCT posts.id")
}
def self.user_tag_stream(user, tag_ids)
......
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Veuillez vous inscrire ou vous pour commenter