mirror of
https://github.com/flarum/core.git
synced 2025-07-22 17:21:27 +02:00
Fix permissions being incorrectly granted
This commit is contained in:
@@ -69,7 +69,7 @@ class CoreServiceProvider extends AbstractServiceProvider
|
|||||||
});
|
});
|
||||||
|
|
||||||
$this->app->make('flarum.gate')->before(function (User $actor, $ability, $model = null) {
|
$this->app->make('flarum.gate')->before(function (User $actor, $ability, $model = null) {
|
||||||
if ($actor->hasPermission($ability)) {
|
if (! $model && $actor->hasPermission($ability)) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user