Conditions | 3 |
Paths | 3 |
Total Lines | 15 |
Code Lines | 9 |
Lines | 0 |
Ratio | 0 % |
Tests | 10 |
CRAP Score | 3 |
Changes | 0 |
1 | <?php |
||
13 | 61 | public function normalize($method, $args): array |
|
14 | { |
||
15 | 61 | $normalizer = resolve(RouteNormalizer::class); |
|
16 | 61 | $method = str_replace('whenYou', '', $method); |
|
17 | 61 | if ($method == 'CallAction') { |
|
18 | 10 | return [$normalizer->normalizeAction($args)]; |
|
19 | } |
||
20 | 54 | if ($method == 'HitRouteName') { |
|
21 | 11 | return [$args]; |
|
22 | } |
||
23 | |||
24 | 43 | $method = str_replace('VisitUrl', 'SendGet', $method); |
|
25 | 43 | $method = str_replace('Send', '', $method); |
|
26 | |||
27 | 43 | return [$normalizer->normalizeUrl($args, strtoupper($method))]; |
|
28 | } |
||
30 |