| Conditions | 1 |
| Paths | 1 |
| Total Lines | 11 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 6 |
| CRAP Score | 1 |
| Changes | 0 | ||
| 1 | <?php |
||
| 21 | 4 | public function getUserSubscribersCountById(int $id): int |
|
| 22 | { |
||
| 23 | 4 | $qb = $this->createQueryBuilder('s'); |
|
| 24 | 4 | return $qb |
|
| 25 | 4 | ->select('COUNT(s.subscriber)') |
|
| 26 | 4 | ->innerJoin('s.author', 'sa') |
|
| 27 | 4 | ->where('sa.id = :id') |
|
| 28 | ->setParameter('id', $id) |
||
| 29 | ->getQuery()->getSingleScalarResult() |
||
| 30 | ; |
||
| 31 | } |
||
| 32 | |||
| 49 | } |