Completed
Push — master ( d55531...cfe428 )
by Amine
02:42
created
src/Placeholder.php 2 patches
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -8,14 +8,14 @@
 block discarded – undo
8 8
  */
9 9
 class Placeholder {
10 10
     private static $instance;
11
-    private function __construct(){}
11
+    private function __construct() {}
12 12
     public static function get()
13 13
     {
14
-        if(static::$instance === null)
14
+        if (static::$instance === null)
15 15
             static::$instance = new Placeholder;
16 16
         return static::$instance;
17 17
     }
18
-    public function __toString(){
18
+    public function __toString() {
19 19
         return '__';
20 20
     }
21 21
 }
Please login to merge, or discard this patch.
Braces   +3 added lines, -2 removed lines patch added patch discarded remove patch
@@ -11,8 +11,9 @@
 block discarded – undo
11 11
     private function __construct(){}
12 12
     public static function get()
13 13
     {
14
-        if(static::$instance === null)
15
-            static::$instance = new Placeholder;
14
+        if(static::$instance === null) {
15
+                    static::$instance = new Placeholder;
16
+        }
16 17
         return static::$instance;
17 18
     }
18 19
     public function __toString(){
Please login to merge, or discard this patch.
try.php 2 patches
Spacing   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -2,8 +2,7 @@
 block discarded – undo
2 2
 
3 3
 function numberOfArgs($fn) {
4 4
     $reflector = is_array($fn) ?
5
-        new ReflectionMethod($fn[0], $fn[1]) :
6
-        new ReflectionFunction($fn);
5
+        new ReflectionMethod($fn[0], $fn[1]) : new ReflectionFunction($fn);
7 6
     return $reflector->getNumberOfParameters();
8 7
 }
9 8
 
Please login to merge, or discard this patch.
Braces   +3 added lines, -2 removed lines patch added patch discarded remove patch
@@ -14,8 +14,9 @@
 block discarded – undo
14 14
 function curriedFunction($fn, $argsCount, $boundArgs = []) {
15 15
     return function() use($fn, $argsCount, $boundArgs) {
16 16
         $boundArgs = array_merge($boundArgs, func_get_args());
17
-        if (count($boundArgs) >= $argsCount)
18
-            return call_user_func_array($fn, $boundArgs);
17
+        if (count($boundArgs) >= $argsCount) {
18
+                    return call_user_func_array($fn, $boundArgs);
19
+        }
19 20
         return curriedFunction($fn, $argsCount, $boundArgs);
20 21
     };
21 22
 }
Please login to merge, or discard this patch.