Wobs 3298

Good point, not entirely sure!

> On 11.06.2014, at 17:08, Paweł Mikołajczuk <notifications@github.com> wrote:
> 
> In newscoop/library/Newscoop/Entity/Repository/UserRepository.php:
> 
> > @@ -701,9 +701,13 @@ public function getListByCriteria(UserCriteria $criteria, $results = true)
> >          }
> >  
> >          if (!empty($criteria->groups)) {
> > -            $op = $criteria->excludeGroups ? 'NOT IN' : 'IN';
> > -            $qb->andWhere("u.id {$op} (SELECT _u.id FROM Newscoop\Entity\User\Group g INNER JOIN g.users _u WHERE g.id IN (:groups))");
> > -            $qb->setParameter('groups', $criteria->groups);
> > +            $em = $this->getEntityManager();
> > +            $groupRepo = $em->getRepository('Newscoop\Entity\User\Group');
> > +            $group = $groupRepo->findOneById($criteria->groups);
> find one will be ok? i think that $criteria->groups can be array and can have multiple results.
> 
> —
> Reply to this email directly or view it on GitHub.