| Conditions | 1 |
| Paths | 1 |
| Total Lines | 13 |
| Code Lines | 7 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 29 | public function getPage(ServerRequestInterface $request): ?BlockInterface |
||
| 30 | { |
||
| 31 | $uri = $request->getUri(); |
||
| 32 | $domain = $uri->getHost(); |
||
| 33 | $url = $uri->getPath(); |
||
| 34 | |||
| 35 | $page = $this->pageRegistry->getPage($url, $domain); |
||
| 36 | |||
| 37 | $block = new Block($this->themeRegistry->getThemeDescriptor($page->getTheme()), [ |
||
| 38 | 'content' => [ $page->getContent() ] |
||
| 39 | ]); |
||
| 40 | |||
| 41 | return $block; |
||
| 42 | } |
||
| 44 |