Total Complexity | 4 |
Total Lines | 39 |
Duplicated Lines | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
25 | class ShowExceptionController extends BackendController |
||
26 | { |
||
27 | /** |
||
28 | * @var RuntimeService |
||
29 | */ |
||
30 | protected $runtimeService; |
||
31 | |||
32 | /** |
||
33 | * This action will be called if an exception was thrown during the building |
||
34 | * of the definition. The exception will be displayed, using TYPO3 core |
||
35 | * exception handling. |
||
36 | * |
||
37 | * @throws Throwable |
||
38 | */ |
||
39 | public function processAction() |
||
40 | { |
||
41 | $exception = $this->runtimeService->getException(); |
||
42 | |||
43 | if (!$exception) { |
||
|
|||
44 | $this->forward('process', 'ShowDefinition'); |
||
45 | } |
||
46 | |||
47 | throw $exception; |
||
48 | } |
||
49 | |||
50 | /** |
||
51 | * @inheritdoc |
||
52 | */ |
||
53 | protected function getMenu(): string |
||
54 | { |
||
55 | return Menu::ADMINISTRATION_DEFINITION; |
||
56 | } |
||
57 | |||
58 | /** |
||
59 | * @param RuntimeService $runtimeService |
||
60 | */ |
||
61 | public function injectRuntimeService(RuntimeService $runtimeService) |
||
64 | } |
||
65 | } |
||
66 |