1
0
mirror of https://github.com/flarum/core.git synced 2025-10-21 19:56:29 +02:00

Remove use of event priorities

Event priorities are no longer in Laravel - see dbbfc62bef

Updated the AbstractPolicy terminology to reflect the new behaviour,
which is that there is no guarantee that the catch-all methods will run
after all specific methods have run globally. This behaviour is only
guaranteed within the policy.
This commit is contained in:
Toby Zerner
2018-01-11 14:10:37 +10:30
parent 801d619a36
commit ae2e07e94c
5 changed files with 17 additions and 17 deletions

View File

@@ -60,7 +60,7 @@ class PostPolicy extends AbstractPolicy
* @param \Flarum\Post\Post $post
* @return bool|null
*/
public function after(User $actor, $ability, Post $post)
public function can(User $actor, $ability, Post $post)
{
if ($actor->can($ability.'Posts', $post->discussion)) {
return true;