This commit is contained in:
Benjamin Takats
2023-01-18 23:25:57 +01:00
parent e92fa90962
commit 107ef6fd81
3 changed files with 27 additions and 27 deletions

View File

@@ -19,20 +19,17 @@ class HorizonServiceProvider extends HorizonApplicationServiceProvider
// Horizon::routeMailNotificationsTo('example@example.com');
// Horizon::routeSlackNotificationsTo('slack-webhook-url', '#channel');
// Horizon::night();
Horizon::night();
}
/**
* Register the Horizon gate.
*
* This gate determines who can access Horizon in non-local environments.
*/
protected function gate(): void
{
Gate::define('viewHorizon', function ($user) {
return in_array($user->email, [
//
]);
return $user->hasRole('super-admin');
});
}
}