/**
  * @param User     $user
  * @param Category $category
  *
  * @return bool
  */
 public function destroy($user, $category)
 {
     return $user->owns($category) || $user->can('support.category.destroy');
 }
示例#2
0
 /**
  * @param User $user
  * @param Post $post
  *
  * @return bool
  */
 public function destroy($user, $post)
 {
     return $user->owns($post) || $user->can('blog.post.destroy');
 }