Completed
Pull Request — master (#24)
by Rafał
03:08
created

GatewayRepository::findActive()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 11
Code Lines 6

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 0
loc 11
rs 9.4285
cc 1
eloc 6
nc 1
nop 0
1
<?php
2
3
/**
4
 * @author Rafał Muszyński <[email protected]>
5
 * @copyright 2015 Sourcefabric z.ú.
6
 * @license http://www.gnu.org/licenses/gpl-3.0.txt
7
 */
8
namespace Newscoop\PaywallBundle\Entity\Repository;
9
10
use Doctrine\ORM\EntityRepository;
11
12
/**
13
 * Gateway repository.
14
 */
15
class GatewayRepository extends EntityRepository
16
{
17
    /**
18
     * Finds active gateways/pament methods.
19
     */
20
    public function findActive()
21
    {
22
        $qb = $this
23
            ->createQueryBuilder('d')
24
            ->where('d.isActive = true')
25
        ;
26
27
        return $qb
28
            ->getQuery()
29
        ;
30
    }
31
}
32