CommunityRepository   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 9
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
dl 0
loc 9
ccs 5
cts 5
cp 1
rs 10
c 0
b 0
f 0
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A countAll() 0 7 1
1
<?php
2
3
namespace App\Repository\Community;
4
5
use Doctrine\ORM\EntityRepository;
6
7
class CommunityRepository extends EntityRepository
8
{
9 1
    public function countAll()
10
    {
11
        return (int) $this
12 1
            ->createQueryBuilder('c')
13 1
            ->select('COUNT(c) as nb_communities')
14 1
            ->getQuery()
15 1
            ->getSingleScalarResult()
16
        ;
17
    }
18
}