Conditions | 3 |
Paths | 3 |
Total Lines | 13 |
Code Lines | 6 |
Lines | 0 |
Ratio | 0 % |
Changes | 5 | ||
Bugs | 1 | Features | 2 |
1 | <?php |
||
35 | public function handle(string $view, array $parameters = []): JsonResponse |
||
36 | { |
||
37 | /** @var MutatorInterface $mutator */ |
||
38 | foreach ($this->container->getMutators() as $mutator) { |
||
39 | if ($mutator instanceof RenderableInterface) { |
||
40 | $mutator->setView($view); |
||
41 | $mutator->setParameters($parameters); |
||
42 | } |
||
43 | |||
44 | $mutator->mutate($this->handler); |
||
45 | } |
||
46 | |||
47 | return new JsonResponse($this->handler->respond(), JsonResponse::HTTP_OK, self::AJAX_COM_CACHE_CONTROL); |
||
48 | } |
||
50 |