Skip to content

Commit

Permalink
support for php 8.4
Browse files Browse the repository at this point in the history
  • Loading branch information
MarioGattolla committed Nov 26, 2024
1 parent 82cad73 commit 6bee5c3
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/run-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ jobs:
strategy:
fail-fast: false
matrix:
php: [8.3, 8.2, 8.1]
php: [8.4, 8.3, 8.2, 8.1]
laravel: ["^11.0", "^10.0", "^9.0", "^8.12"]
dependency-version: [prefer-lowest, prefer-stable]
include:
Expand Down
6 changes: 3 additions & 3 deletions src/helpers.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
* @param null $guard
* @return bool
*/
function can_impersonate(string $guard = null): bool
function can_impersonate(?string $guard = null): bool
{
$guard = $guard ?? app('impersonate')->getCurrentAuthGuardName();

Expand All @@ -28,7 +28,7 @@ function can_impersonate(string $guard = null): bool
* @param string|null $guard
* @return bool
*/
function can_be_impersonated(Authenticatable $user, string $guard = null): bool
function can_be_impersonated(Authenticatable $user, ?string $guard = null): bool
{
$guard = $guard ?? app('impersonate')->getCurrentAuthGuardName();
return app('auth')->guard($guard)->check()
Expand All @@ -45,7 +45,7 @@ function can_be_impersonated(Authenticatable $user, string $guard = null): bool
* @param string|null $guard
* @return bool
*/
function is_impersonating(string $guard = null): bool
function is_impersonating(?string $guard = null): bool
{
$guard = $guard ?? app('impersonate')->getCurrentAuthGuardName();

Expand Down

0 comments on commit 6bee5c3

Please sign in to comment.