-
-
Notifications
You must be signed in to change notification settings - Fork 382
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix php 8.4 deprecated types #688
Fix php 8.4 deprecated types #688
Conversation
@santigarcor Let me know if something else need to be provided for the PR. |
src/Contracts/LaratrustUser.php
Outdated
@@ -150,5 +150,5 @@ public function syncPermissions( | |||
* | |||
* @return Collection<\Laratrust\Contracts\Permission> | |||
*/ | |||
public function allPermissions(array $columns = null, $team = false): Collection; | |||
public function allPermissions(?array $columns = null, bool $team = false): Collection; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
$team
should be a mixed variable.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@@ -498,7 +498,7 @@ public function syncPermissionsWithoutDetaching( | |||
* | |||
* @return Collection<\Laratrust\Contracts\Permission> | |||
*/ | |||
public function allPermissions(array $columns = null, $team = false): Collection | |||
public function allPermissions(?array $columns = null, bool $team = false): Collection |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
$team
should be a mixed variable.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@incoming-th can you please add |
@santigarcor Sure, I totally forgot about this thanks. |
Fix the PHP 8.4 warning messages:
PHP Deprecated: Laratrust\Traits\HasRolesAndPermissions::allPermissions(): Implicitly marking parameter $columns as nullable is deprecated, the explicit nullable type must be used instead in /vendor/santigarcor/laratrust/src/Traits/HasRolesAndPermissions.php on line 501
PHP Deprecated: Laratrust\Contracts\LaratrustUser::allPermissions(): Implicitly marking parameter $columns as nullable is deprecated, the explicit nullable type must be used instead in /vendor/santigarcor/laratrust/src/Contracts/LaratrustUser.php on line 153