Passed
Push — master ( dce459...9a4b2a )
by Luiz Kim
08:19 queued 05:50
created
src/Service/DomainService.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -57,7 +57,7 @@
 block discarded – undo
57 57
     {
58 58
         if (self::$peopleDomain) return self::$peopleDomain;
59 59
         
60
-        $domain  = $this->getMainDomain();
60
+        $domain = $this->getMainDomain();
61 61
         self::$peopleDomain = $this->manager->getRepository(PeopleDomain::class)->findOneBy(['domain' => $domain]);
62 62
 
63 63
         if (self::$peopleDomain === null)
Please login to merge, or discard this patch.
Braces   +9 added lines, -5 removed lines patch added patch discarded remove patch
@@ -43,8 +43,9 @@  discard block
 block discarded – undo
43 43
             )
44 44
         ));
45 45
 
46
-        if (!$domain)
47
-            throw new InvalidArgumentException('Please define header or get param "app-domain"', 301);
46
+        if (!$domain) {
47
+                    throw new InvalidArgumentException('Please define header or get param "app-domain"', 301);
48
+        }
48 49
         return $domain;
49 50
     }
50 51
 
@@ -55,15 +56,18 @@  discard block
 block discarded – undo
55 56
 
56 57
     public function getPeopleDomain(): PeopleDomain
57 58
     {
58
-        if (self::$peopleDomain) return self::$peopleDomain;
59
+        if (self::$peopleDomain) {
60
+            return self::$peopleDomain;
61
+        }
59 62
         
60 63
         $domain  = $this->getMainDomain();
61 64
         self::$peopleDomain = $this->manager->getRepository(PeopleDomain::class)->findOneBy(['domain' => $domain]);
62 65
 
63
-        if (self::$peopleDomain === null)
64
-            throw new \Exception(
66
+        if (self::$peopleDomain === null) {
67
+                    throw new \Exception(
65 68
                 sprintf('Main company "%s" not found', $domain)
66 69
             );
70
+        }
67 71
 
68 72
         return self::$peopleDomain;
69 73
     }
Please login to merge, or discard this patch.
src/Entity/City.php 1 patch
Indentation   -1 removed lines patch added patch discarded remove patch
@@ -59,7 +59,6 @@
 block discarded – undo
59 59
      *
60 60
      * @ORM\Column(name="cod_ibge", type="integer", nullable=true)
61 61
      * @Groups({"city:read","logistic:read","order_details:read", "people:read", "address:read", "delivery_region:read"})
62
-
63 62
      */
64 63
     private $cod_ibge;
65 64
     /**
Please login to merge, or discard this patch.
src/Entity/State.php 1 patch
Indentation   -1 removed lines patch added patch discarded remove patch
@@ -51,7 +51,6 @@
 block discarded – undo
51 51
      *
52 52
      * @ORM\Column(name="cod_ibge", type="integer", nullable=true)
53 53
      * @Groups({"city:read","logistic:read","state:read", "order_details:read", "people:read", "address:read", "delivery_region:read"})
54
-
55 54
      */
56 55
     private $cod_ibge;
57 56
     /**
Please login to merge, or discard this patch.