mirror of
https://github.com/flarum/core.git
synced 2025-05-05 15:07:17 +02:00
Make sure GetPermission event arguments array is empty if there is no model
This commit is contained in:
parent
6de7038f83
commit
8d671f4de4
@ -78,7 +78,7 @@ class CoreServiceProvider extends AbstractServiceProvider
|
||||
}
|
||||
|
||||
return $this->app->make('events')->until(
|
||||
new GetPermission($actor, $ability, [$model])
|
||||
new GetPermission($actor, $ability, $model ? [$model] : [])
|
||||
);
|
||||
});
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user