StaticController::generateStatic()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 2
nc 1
nop 1
dl 0
loc 5
rs 10
c 0
b 0
f 0
1
<?php
2
3
namespace PiedWeb\CMSBundle\Extension\StaticGenerator;
4
5
use Sensio\Bundle\FrameworkExtraBundle\Configuration\Security;
6
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
7
8
class StaticController extends AbstractController
9
{
10
    /**
11
     * @Security("is_granted('ROLE_EDITOR')")
12
     */
13
    public function generateStatic(StaticAppGenerator $staticAppGenerator)
14
    {
15
        $staticAppGenerator->generateAll();
16
17
        return $this->render('@pwcStaticGenerator/results.html.twig');
18
    }
19
}
20