Homepage::__invoke()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 14
Code Lines 11

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 0
Metric Value
cc 1
eloc 11
nc 1
nop 0
dl 0
loc 14
ccs 2
cts 2
cp 1
crap 1
rs 9.9
c 0
b 0
f 0
1
<?php
2
3
/**
4
 * For the full copyright and license information, please view
5
 * the LICENSE file that was distributed with this source code.
6
 *
7
 * @see https://github.com/ecphp
8
 */
9
10
declare(strict_types=1);
11
12
namespace EcPhp\CasBundle\Controller;
13
14
use Symfony\Component\HttpFoundation\Response;
15
16
final class Homepage
17
{
18 1
    public function __invoke(): Response
19
    {
20
        $body = <<< 'EOF'
21
            <p>You have been redirected here by default.
22
            You are most probably using the default CAS configuration.</p>
23
24
            <p>The default CAS bundle configuration should be installed in
25
            <code>config/packages/dev/cas_bundle.yaml</code></p>
26
27
            <p>Please update your configuration and replace <code>cas_bundle_homepage</code>
28
            with an existing route of your app.</p>
29
            EOF;
30
31 1
        return new Response($body);
32
    }
33
}
34