Passed
Push — main ( ba6688...9c4ee4 )
by Sammy
07:19 queued 05:00
created
LeMarchand.php 1 patch
Braces   +12 added lines, -8 removed lines patch added patch discarded remove patch
@@ -104,14 +104,17 @@  discard block
 block discarded – undo
104 104
             $class_name = $this->cascadeNamespace($m[1].'\\'.$m[2]);
105 105
             // vd($configuration, $class_name);
106 106
 
107
-            if(!isset($m[3]))
108
-              return $this->getInstance($class_name);
107
+            if(!isset($m[3])) {
108
+                          return $this->getInstance($class_name);
109
+            }
109 110
 
110
-            if($m[3] === '::class')
111
-              return $class_name;
111
+            if($m[3] === '::class') {
112
+                          return $class_name;
113
+            }
112 114
 
113
-            if($m[3] === '::new')
114
-              return $this->makeInstance($class_name);
115
+            if($m[3] === '::new') {
116
+                          return $this->makeInstance($class_name);
117
+            }
115 118
         }
116 119
 
117 120
         // if it is an interface, we respond with an instance
@@ -208,8 +211,9 @@  discard block
 block discarded – undo
208 211
 
209 212
     private function getInstance($class, $construction_args = [])
210 213
     {
211
-        if(isset($this->instance_cache[$class]))
212
-          return $this->instance_cache[$class];
214
+        if(isset($this->instance_cache[$class])) {
215
+                  return $this->instance_cache[$class];
216
+        }
213 217
 
214 218
         return $this->makeInstance($class, $construction_args);
215 219
     }
Please login to merge, or discard this patch.