Skip to content

Commit f289070

Browse files
authored
Fix implicitly nullable parameters for PHP 8.4 (#35)
* Fix implicitly nullable parameters for PHP 8.4 * Add 8.4 to test matrix
1 parent 2df3a6d commit f289070

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

.github/workflows/tests.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
strategy:
1717
fail-fast: true
1818
matrix:
19-
php: [7.2, 7.3, 7.4, '8.0', 8.1, 8.2, 8.3]
19+
php: [7.2, 7.3, 7.4, '8.0', 8.1, 8.2, 8.3, 8.4]
2020

2121
name: PHP ${{ matrix.php }}
2222

src/helpers.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ function array_except($array, $keys)
8181
* @param mixed $default
8282
* @return mixed
8383
*/
84-
function array_first($array, callable $callback = null, $default = null)
84+
function array_first($array, ?callable $callback = null, $default = null)
8585
{
8686
return Arr::first($array, $callback, $default);
8787
}
@@ -153,7 +153,7 @@ function array_has($array, $keys)
153153
* @param mixed $default
154154
* @return mixed
155155
*/
156-
function array_last($array, callable $callback = null, $default = null)
156+
function array_last($array, ?callable $callback = null, $default = null)
157157
{
158158
return Arr::last($array, $callback, $default);
159159
}

0 commit comments

Comments
 (0)