@@ -48,7 +48,7 @@ |
||
| 48 | 48 | |
| 49 | 49 | public function __construct(/* \Iterator $iterable1, \Iterator $iterable2, ... */) |
| 50 | 50 | { |
| 51 | - parent::__construct(\MultipleIterator::MIT_NEED_ALL| \MultipleIterator::MIT_KEYS_NUMERIC); |
|
| 51 | + parent::__construct(\MultipleIterator::MIT_NEED_ALL|\MultipleIterator::MIT_KEYS_NUMERIC); |
|
| 52 | 52 | foreach (func_get_args() as $iterable) { |
| 53 | 53 | if (!$iterable instanceof \Iterator) { |
| 54 | 54 | throw new \InvalidArgumentException(sprintf('Not all arguments are iterators')); |
@@ -61,11 +61,11 @@ discard block |
||
| 61 | 61 | |
| 62 | 62 | public function __construct(\Closure $valueFunc /* [\Closure $keyFunc], \Iterator $iterable1, [\Iterator $iterable2, [...]] */) |
| 63 | 63 | { |
| 64 | - parent::__construct(\MultipleIterator::MIT_NEED_ALL| \MultipleIterator::MIT_KEYS_NUMERIC); |
|
| 64 | + parent::__construct(\MultipleIterator::MIT_NEED_ALL|\MultipleIterator::MIT_KEYS_NUMERIC); |
|
| 65 | 65 | $args = func_get_args(); |
| 66 | 66 | $argsContainsKeyFunc = $args[1] instanceof \Closure; |
| 67 | 67 | $this->valueFunc = $args[0]; |
| 68 | - $this->keyFunc = $argsContainsKeyFunc ? $args[1] : function () { return $this->genericKeysToKey(func_get_args()); }; |
|
| 68 | + $this->keyFunc = $argsContainsKeyFunc ? $args[1] : function() { return $this->genericKeysToKey(func_get_args()); }; |
|
| 69 | 69 | foreach (array_slice($args, $argsContainsKeyFunc ? 2 : 1) as $iterable) { |
| 70 | 70 | if (!$iterable instanceof \Iterator) { |
| 71 | 71 | throw new \InvalidArgumentException(sprintf('Not all arguments are iterators')); |
@@ -86,7 +86,7 @@ discard block |
||
| 86 | 86 | foreach ($keys as $key) { |
| 87 | 87 | if ($key !== $value) { |
| 88 | 88 | // the keys are different, we will make a new string identifying this entry |
| 89 | - return join(':', array_map(function ($key) { return (string)$key; }, $keys)); |
|
| 89 | + return join(':', array_map(function($key) { return (string)$key; }, $keys)); |
|
| 90 | 90 | } |
| 91 | 91 | } |
| 92 | 92 | |