mirror of
https://github.com/flarum/framework.git
synced 2024-11-25 04:28:47 +08:00
Fix permissions being incorrectly granted
This commit is contained in:
parent
17619843b5
commit
90def3f0db
|
@ -69,7 +69,7 @@ class CoreServiceProvider extends AbstractServiceProvider
|
|||
});
|
||||
|
||||
$this->app->make('flarum.gate')->before(function (User $actor, $ability, $model = null) {
|
||||
if ($actor->hasPermission($ability)) {
|
||||
if (! $model && $actor->hasPermission($ability)) {
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user