Completed
Branch master (a1753a)
by Mikhail
01:53
created
src/SilexDoctrineHydrationProfile/Fix/FixHydrationDataCollector.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -16,7 +16,7 @@
 block discarded – undo
16 16
     /**
17 17
      * @var HydrationLogger
18 18
      */
19
-    protected $hydrationLogger = array ();
19
+    protected $hydrationLogger = array();
20 20
 
21 21
     public function __construct(HydrationLogger $logger)
22 22
     {
Please login to merge, or discard this patch.
src/SilexDoctrineHydrationProfile/Fix/FixDoctrineProvider.php 1 patch
Spacing   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -44,7 +44,7 @@  discard block
 block discarded – undo
44 44
                     $config = $app['orm.ems.config'][$name];
45 45
                 }
46 46
 
47
-                $ems[$name] = $app->share(function () use ($app, $options, $config) {
47
+                $ems[$name] = $app->share(function() use ($app, $options, $config) {
48 48
                     /**
49 49
                      * @var $entityManagerClassName \Doctrine\ORM\EntityManager
50 50
                      */
@@ -102,7 +102,7 @@  discard block
 block discarded – undo
102 102
                     }
103 103
 
104 104
                     if (!empty($entity['resources_namespace'])) {
105
-                        if($app->offsetExists('psr0_resource_locator')) {
105
+                        if ($app->offsetExists('psr0_resource_locator')) {
106 106
                             $entity['path'] = $app['psr0_resource_locator']->findFirstDirectory($entity['resources_namespace']);
107 107
                         } else {
108 108
                             throw new \InvalidArgumentException('Not exist psr0_resource_locator');
@@ -113,13 +113,13 @@  discard block
 block discarded – undo
113 113
                         $config->addEntityNamespace($entity['alias'], $entity['namespace']);
114 114
                     }
115 115
 
116
-                    if('annotation' === $entity['type']){
116
+                    if ('annotation' === $entity['type']) {
117 117
                         $useSimpleAnnotationReader = isset($entity['use_simple_annotation_reader'])
118 118
                             ? $entity['use_simple_annotation_reader']
119 119
                             : true;
120
-                        $driver =  $config->newDefaultAnnotationDriver((array) $entity['path'], $useSimpleAnnotationReader);
120
+                        $driver = $config->newDefaultAnnotationDriver((array) $entity['path'], $useSimpleAnnotationReader);
121 121
                     } else {
122
-                        $driver = $app['orm.driver.factory']( $entity, $options );
122
+                        $driver = $app['orm.driver.factory']($entity, $options);
123 123
                     }
124 124
                     $chain->addDriver($driver, $entity['namespace']);
125 125
                 }
@@ -140,15 +140,15 @@  discard block
 block discarded – undo
140 140
         });
141 141
 
142 142
 
143
-        $app['orm.driver.factory'] = $app->share(function(){
143
+        $app['orm.driver.factory'] = $app->share(function() {
144 144
             $simpleList = array(
145 145
                 'simple_yml',
146 146
                 'simple_xml',
147 147
             );
148
-            return function ( $entity, $options ) use ($simpleList) {
149
-                if (isset($options[ 'class.driver.' . $entity['type'] ])) {
150
-                    $className = $options[ 'class.driver.' . $entity['type'] ];
151
-                    if( in_array($entity['type'], $simpleList) ) {
148
+            return function($entity, $options) use ($simpleList) {
149
+                if (isset($options['class.driver.'.$entity['type']])) {
150
+                    $className = $options['class.driver.'.$entity['type']];
151
+                    if (in_array($entity['type'], $simpleList)) {
152 152
                         $param = array($entity['path'] => $entity['namespace']);
153 153
                     } else {
154 154
                         $param = $entity['path'];
Please login to merge, or discard this patch.