Conditions | 2 |
Paths | 2 |
Total Lines | 11 |
Code Lines | 5 |
Lines | 0 |
Ratio | 0 % |
Tests | 6 |
CRAP Score | 2 |
Changes | 0 |
1 | <?php |
||
13 | 2 | public function execute() |
|
14 | { |
||
15 | /** @var Form $form */ |
||
16 | 2 | $form = $this->getFromResponse('form'); |
|
17 | 2 | $form->handleRequest($this->request); |
|
18 | |||
19 | 2 | if (!$form->isSubmitted()) { |
|
20 | 1 | throw new BadRequestHttpException('Form is supposed to be submitted with this request'); |
|
21 | } |
||
22 | |||
23 | 1 | return $this->createResponse(['form' => $form]); |
|
24 | } |
||
31 | } |