Conditions | 2 |
Paths | 2 |
Total Lines | 7 |
Code Lines | 3 |
Lines | 0 |
Ratio | 0 % |
Tests | 4 |
CRAP Score | 2 |
Changes | 0 |
1 | <?php |
||
13 | 2 | public function getResourceName(Request $request): string |
|
14 | { |
||
15 | 2 | if (!$this->supports($request)) { |
|
16 | 1 | throw new Exception('No admin resource was found in the request. The route is wrongly configured'); |
|
17 | } |
||
18 | |||
19 | 1 | return $request->get('_route_params')[LAGAdminBundle::REQUEST_PARAMETER_ADMIN]; |
|
20 | } |
||
49 |