你如何通过Laravel授权在帖子上写“canDeleteComment”的政策?

I have posts, the posts have comments. What I need to do is authorize both the comment author and the post author to delete a comment on the same post. Idea is the author of the post being commented is able to delete unwanted comments from his posts and the author of the comments is also able to delete the comments he left. I see you can pass multiple variables to the Gate facade. So I'm thinking I can write the policy like this:

    class CommentPolicy
    {
        public function deleteComment(User $user, Comment $comment, Post $post)
        {        
            //mumbo jumbo goes here
        }

    }

But ok, what do you put in the logic part of that policy? I was thinking maybe this:

return ($user->id === $comment->user_id || $user->id === $post->user_id);

or maybe:

$check =  array ($user->id === $comment->user_id,  $user->id === $post->user_id);

        if (($check[0] = 0) && ($check[1] = 0)){

            return 0;

        }else{

            return 1;
        }

but is this legit? I mean can php return values this way? And if not how do you check these conditions?