Properly return allow / deny instead of boolean

This commit is contained in:
Alexander Skvortsov 2020-12-17 19:51:53 -05:00
parent 64d965fa17
commit c9b9c1ddce

View File

@ -34,6 +34,6 @@ class TagPolicy extends AbstractPolicy
*/
public function addToDiscussion(User $actor, Tag $tag)
{
return $actor->can('startDiscussion', $tag);
return $actor->can('startDiscussion', $tag) ? $this->allow() : $this->deny();
}
}