SuluCommentBundle::build()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 10
Code Lines 5

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 4
CRAP Score 1

Importance

Changes 0
Metric Value
dl 0
loc 10
ccs 4
cts 4
cp 1
rs 9.4285
c 0
b 0
f 0
cc 1
eloc 5
nc 1
nop 1
crap 1
1
<?php
2
3
/*
4
 * This file is part of Sulu.
5
 *
6
 * (c) MASSIVE ART WebServices GmbH
7
 *
8
 * This source file is subject to the MIT license that is bundled
9
 * with this source code in the file LICENSE.
10
 */
11
12
namespace Sulu\Bundle\CommentBundle;
13
14
use Sulu\Bundle\CommentBundle\Entity\CommentInterface;
15
use Sulu\Bundle\CommentBundle\Entity\ThreadInterface;
16
use Sulu\Bundle\PersistenceBundle\PersistenceBundleTrait;
17
use Symfony\Component\DependencyInjection\ContainerBuilder;
18
use Symfony\Component\HttpKernel\Bundle\Bundle;
19
20
/**
21
 * Register the bundles compiler passes.
22
 */
23
class SuluCommentBundle extends Bundle
24
{
25
    use PersistenceBundleTrait;
26
27
    /**
28
     * {@inheritdoc}
29
     */
30 2
    public function build(ContainerBuilder $container)
31
    {
32 2
        $this->buildPersistence(
33
            [
34 2
                CommentInterface::class => 'sulu.model.comment.class',
35
                ThreadInterface::class => 'sulu.model.thread.class',
36
            ],
37
            $container
38
        );
39 2
    }
40
}
41