Completed
Push — master ( df496b...1f2156 )
by Garrett
02:26
created
src/Dice.php 3 patches
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -243,7 +243,7 @@
 block discarded – undo
243 243
             }
244 244
 
245 245
             //variadic functions will only have one argument. To account for those, append any remaining arguments to the list
246
-			return array_merge($parameters, $args);
246
+            return array_merge($parameters, $args);
247 247
         };
248 248
     }
249 249
 
Please login to merge, or discard this patch.
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -15,9 +15,9 @@  discard block
 block discarded – undo
15 15
 
16 16
 class Dice
17 17
 {
18
-    private $rules = [];        // Rules which have been set using addRule()
19
-    private $cache = [];        // A cache of closures based on class name so each class is only reflected once
20
-    private $instances = [];    // Stores any instances marked as 'shared' so create() can return the same instance
18
+    private $rules = []; // Rules which have been set using addRule()
19
+    private $cache = []; // A cache of closures based on class name so each class is only reflected once
20
+    private $instances = []; // Stores any instances marked as 'shared' so create() can return the same instance
21 21
 
22 22
     /**
23 23
      * Constructor which allows setting a default ruleset to apply to all objects.
@@ -97,7 +97,7 @@  discard block
 block discarded – undo
97 97
 
98 98
         //If there are shared instances, create them and merge them with shared instances higher up the object graph
99 99
         if (isset($rule['shareInstances'])) {
100
-            $closure = function(array $args, array $share) use ($closure, $rule) {
100
+            $closure = function (array $args, array $share) use ($closure, $rule) {
101 101
                 return $closure($args, array_merge($args, $share, array_map([$this, 'create'], $rule['shareInstances'])));
102 102
             };
103 103
         }
Please login to merge, or discard this patch.
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -212,7 +212,8 @@
 block discarded – undo
212 212
                 list($class, $param, $sub) = $pi;
213 213
 
214 214
                 // First, loop through $args and see if each value can match the current parameter based on type hint
215
-                if (!empty($args)) { // This if statement actually gives a ~10% speed increase when $args isn't set
215
+                if (!empty($args)) {
216
+// This if statement actually gives a ~10% speed increase when $args isn't set
216 217
                     foreach ($args as $i => $arg) {
217 218
                         if ($class !== null
218 219
                             && ($arg instanceof $class || ($arg === null && $param->allowsNull()))
Please login to merge, or discard this patch.
src/Loader/Json.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -25,7 +25,7 @@
 block discarded – undo
25 25
 
26 26
         $map = json_decode($json, true);
27 27
         if (!is_array($map)) {
28
-            throw new \Exception('Could not decode json: ' . json_last_error_msg());
28
+            throw new \Exception('Could not decode json: '.json_last_error_msg());
29 29
         }
30 30
 
31 31
         if (isset($map['rules'])) {
Please login to merge, or discard this patch.