mirror of
https://github.com/flarum/core.git
synced 2025-08-12 11:24:30 +02:00
chore: increase phpstan level to 6 (#3836)
* chore: increase phpstan level to 6 Signed-off-by: Sami Mazouz <sychocouldy@gmail.com> * Apply fixes from StyleCI --------- Signed-off-by: Sami Mazouz <sychocouldy@gmail.com> Co-authored-by: StyleCI Bot <bot@styleci.io>
This commit is contained in:
@@ -14,10 +14,12 @@ use Flarum\User\User;
|
||||
|
||||
class UserPolicy extends AbstractPolicy
|
||||
{
|
||||
public function suspend(User $actor, User $user)
|
||||
public function suspend(User $actor, User $user): ?string
|
||||
{
|
||||
if ($user->isAdmin() || $user->id === $actor->id) {
|
||||
return $this->deny();
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user