@@ -16,7 +16,7 @@ |
||
| 16 | 16 | { |
| 17 | 17 | const MAPPER_TAG = 'request_mapper'; |
| 18 | 18 | |
| 19 | - const REQUEST_MAPPER_ID='fesor.request_object.mapper'; |
|
| 19 | + const REQUEST_MAPPER_ID = 'fesor.request_object.mapper'; |
|
| 20 | 20 | |
| 21 | 21 | public function load(array $configs, ContainerBuilder $container) |
| 22 | 22 | { |
@@ -55,7 +55,9 @@ |
||
| 55 | 55 | $tags = []; |
| 56 | 56 | |
| 57 | 57 | foreach ($services as $id => $service) { |
| 58 | - if (!is_array($service)) $service = [$service, []]; |
|
| 58 | + if (!is_array($service)) { |
|
| 59 | + $service = [$service, []]; |
|
| 60 | + } |
|
| 59 | 61 | list($className, $tagAttributes) = $service; |
| 60 | 62 | |
| 61 | 63 | $tags[$id] = $tagAttributes; |
@@ -28,7 +28,7 @@ discard block |
||
| 28 | 28 | $classReflection = new \ReflectionClass($mapper->getClass()); |
| 29 | 29 | $publicMethods = $classReflection->getMethods(\ReflectionMethod::IS_PUBLIC); |
| 30 | 30 | |
| 31 | - $mapperMethods = array_filter($publicMethods, function (\ReflectionMethod $method) { |
|
| 31 | + $mapperMethods = array_filter($publicMethods, function(\ReflectionMethod $method) { |
|
| 32 | 32 | return $method->hasReturnType(); |
| 33 | 33 | }); |
| 34 | 34 | |
@@ -44,7 +44,7 @@ discard block |
||
| 44 | 44 | { |
| 45 | 45 | $tags = $builder->findTaggedServiceIds(RequestObjectExtension::MAPPER_TAG); |
| 46 | 46 | |
| 47 | - uasort($tags, function ($a, $b) { |
|
| 47 | + uasort($tags, function($a, $b) { |
|
| 48 | 48 | |
| 49 | 49 | return ($a['priority'] ?? 0) <=> ($b['priority'] ?? 0); |
| 50 | 50 | }); |