DoctrineSerializerPass   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 14
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
wmc 2
lcom 0
cbo 1
dl 0
loc 14
ccs 5
cts 5
cp 1
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A process() 0 8 2
1
<?php
2
3
namespace TreeHouse\QueueBundle\DependencyInjection\Compiler;
4
5
use Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface;
6
use Symfony\Component\DependencyInjection\ContainerBuilder;
7
8
class DoctrineSerializerPass implements CompilerPassInterface
9
{
10
    /**
11
     * @inheritdoc
12
     */
13 3
    public function process(ContainerBuilder $container)
14
    {
15 3
        if (!$container->hasDefinition('doctrine')) {
16 2
            $container->removeDefinition('tree_house.queue.serializer.doctrine');
17
18 2
            return;
19
        }
20 1
    }
21
}
22