@@ -10,14 +10,14 @@ |
||
10 | 10 | ); |
11 | 11 | |
12 | 12 | $countries = F\pipe( |
13 | - F\map(function ($x) { |
|
13 | + F\map(function($x) { |
|
14 | 14 | return $x['country']; |
15 | 15 | }), |
16 | 16 | $join |
17 | 17 | ); |
18 | 18 | |
19 | 19 | $cities = F\pipe( |
20 | - F\map(function ($x) { |
|
20 | + F\map(function($x) { |
|
21 | 21 | return $x['cities']; |
22 | 22 | }), |
23 | 23 | $join |
@@ -11,7 +11,7 @@ |
||
11 | 11 | { |
12 | 12 | $args = func_get_args(); |
13 | 13 | |
14 | - $id = function ($x) { |
|
14 | + $id = function($x) { |
|
15 | 15 | return $x; |
16 | 16 | }; |
17 | 17 |
@@ -11,19 +11,19 @@ |
||
11 | 11 | { |
12 | 12 | $args = func_get_args(); |
13 | 13 | $placeholder = pipe( |
14 | - filter(function ($x) { |
|
14 | + filter(function($x) { |
|
15 | 15 | return _ === $x; |
16 | 16 | }), |
17 | - function ($xs) { |
|
17 | + function($xs) { |
|
18 | 18 | return array_keys($xs) ?: []; |
19 | 19 | } |
20 | 20 | ); |
21 | 21 | |
22 | - $hold = function (callable $fn) use ($placeholder) { |
|
22 | + $hold = function(callable $fn) use ($placeholder) { |
|
23 | 23 | $args = array_slice(func_get_args(), 1); |
24 | 24 | $ks = $placeholder($args); |
25 | 25 | |
26 | - return function ($x) use ($fn, $args, $ks) { |
|
26 | + return function($x) use ($fn, $args, $ks) { |
|
27 | 27 | if ([] === $ks) { |
28 | 28 | return call_user_func_array($fn, array_merge($args, [$x])); |
29 | 29 | } |