cleanup default controller
This commit is contained in:
parent
0dff733727
commit
32cb737f6b
|
@ -19,13 +19,13 @@ class PageController extends AbstractController
|
||||||
$this->siteStore = $siteStore;
|
$this->siteStore = $siteStore;
|
||||||
}
|
}
|
||||||
|
|
||||||
public function show(Request $request, SiteRequest $siteRequest): Response
|
public function show(): Response
|
||||||
{
|
{
|
||||||
if (!$siteRequest->getPage()) {
|
if (!$this->siteRequest->getPage()) {
|
||||||
throw $this->createNotFoundException();
|
throw $this->createNotFoundException();
|
||||||
}
|
}
|
||||||
|
|
||||||
return $this->defaultRender($siteRequest->getPage()->getTemplate());
|
return $this->defaultRender($this->siteRequest->getPage()->getTemplate());
|
||||||
}
|
}
|
||||||
|
|
||||||
protected function defaultRender(string $view, array $parameters = [], Response $response = null): Response
|
protected function defaultRender(string $view, array $parameters = [], Response $response = null): Response
|
||||||
|
|
Loading…
Reference in a new issue