Completed
Push — master ( 0b2d09...6fed26 )
by Guilh
14:08 queued 04:12
created

JMSFormErrorHandlerPass   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 7
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 1
c 1
b 0
f 0
lcom 0
cbo 1
dl 0
loc 7
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A process() 0 4 1
1
<?php
2
3
/*
4
 * This file is part of the FOSRestBundle package.
5
 *
6
 * (c) FriendsOfSymfony <http://friendsofsymfony.github.com/>
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
12
namespace FOS\RestBundle\DependencyInjection\Compiler;
13
14
use Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface;
15
use Symfony\Component\DependencyInjection\ContainerBuilder;
16
use FOS\RestBundle\Serializer\Normalizer\FormErrorHandler;
17
18
/**
19
 * Changes the JMS FormError handler.
20
 *
21
 * @author Guilhem Niot <[email protected]>
22
 *
23
 * @internal
24
 */
25
final class JMSFormErrorHandlerPass implements CompilerPassInterface
26
{
27
    public function process(ContainerBuilder $container)
28
    {
29
        $container->setParameter('jms_serializer.form_error_handler.class', FormErrorHandler::class);
30
    }
31
}
32