Passed
Push — master ( 0e6745...636694 )
by Luiz Kim
02:03
created
src/Service/ExtraDataService.php 1 patch
Braces   +6 added lines, -4 removed lines patch added patch discarded remove patch
@@ -24,8 +24,9 @@  discard block
 block discarded – undo
24 24
     public function persist()
25 25
     {
26 26
         $extra_data = $this->request->get('extra-data');
27
-        if (!$extra_data)
28
-            return;
27
+        if (!$extra_data) {
28
+                    return;
29
+        }
29 30
         foreach ($extra_data['entity_id']['data'] as $data) {
30 31
             $extra_fields = $this->manager->getRepository(ExtraFields::class)->find($data['id']);
31 32
 
@@ -35,8 +36,9 @@  discard block
 block discarded – undo
35 36
                 'extra_fields' => $extra_fields
36 37
             ]);
37 38
 
38
-            if (!$extraData)
39
-                $extraData = new ExtraData();
39
+            if (!$extraData) {
40
+                            $extraData = new ExtraData();
41
+            }
40 42
 
41 43
             $extraData->setExtraFields($extra_fields);
42 44
             $extraData->setEntityName($extra_data['entity_name']);
Please login to merge, or discard this patch.
src/Listener/DefaultEventListener.php 1 patch
Braces   +3 added lines, -2 removed lines patch added patch discarded remove patch
@@ -51,8 +51,9 @@
 block discarded – undo
51 51
             $service = $this->container->get($serviceName);
52 52
             if (method_exists($service, $method)) {
53 53
                 $entity = $service->$method($entity);
54
-                if ('afterPersist' === $method && $entity)
55
-                    $this->manager->refresh($entity);
54
+                if ('afterPersist' === $method && $entity) {
55
+                                    $this->manager->refresh($entity);
56
+                }
56 57
             }
57 58
         }
58 59
     }
Please login to merge, or discard this patch.