mirror of
https://github.com/flarum/core.git
synced 2025-08-18 14:22:02 +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:
@@ -21,10 +21,12 @@ class LikePostPolicy extends AbstractPolicy
|
||||
) {
|
||||
}
|
||||
|
||||
public function like(User $actor, Post $post)
|
||||
public function like(User $actor, Post $post): ?string
|
||||
{
|
||||
if ($actor->id === $post->user_id && ! (bool) $this->settings->get('flarum-likes.like_own_post')) {
|
||||
return $this->deny();
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user