@@ -18,7 +18,7 @@ discard block |
||
18 | 18 | } |
19 | 19 | } |
20 | 20 | |
21 | - public function get(string|int $index, $default = null): mixed |
|
21 | + public function get(string | int $index, $default = null): mixed |
|
22 | 22 | { |
23 | 23 | return $this->elements[$index] ?? $default; |
24 | 24 | } |
@@ -44,7 +44,7 @@ discard block |
||
44 | 44 | return true; |
45 | 45 | } |
46 | 46 | |
47 | - public function indexOf(mixed $element): bool|int|string |
|
47 | + public function indexOf(mixed $element): bool | int | string |
|
48 | 48 | { |
49 | 49 | return array_search($element, $this->elements, true); |
50 | 50 | } |
@@ -97,7 +97,7 @@ discard block |
||
97 | 97 | return $this; |
98 | 98 | } |
99 | 99 | |
100 | - public function forEach(callable $callback, bool $stopable = false): static |
|
100 | + public function forEach (callable $callback, bool $stopable = false): static |
|
101 | 101 | { |
102 | 102 | foreach ($this->elements as $index => $element) { |
103 | 103 | $result = call_user_func_array($callback, [$element, $index]); |