mirror of
https://github.com/pixelfed/pixelfed.git
synced 2024-11-22 06:21:27 +00:00
Update AppServiceProvider, add UserFilter observer
This commit is contained in:
parent
8a0e1402dd
commit
a417d9bbad
1 changed files with 5 additions and 2 deletions
|
@ -6,13 +6,15 @@ use App\Observers\{
|
|||
AvatarObserver,
|
||||
NotificationObserver,
|
||||
StatusHashtagObserver,
|
||||
UserObserver
|
||||
UserObserver,
|
||||
UserFilterObserver,
|
||||
};
|
||||
use App\{
|
||||
Avatar,
|
||||
Notification,
|
||||
StatusHashtag,
|
||||
User
|
||||
User,
|
||||
UserFilter
|
||||
};
|
||||
use Auth, Horizon, URL;
|
||||
use Illuminate\Support\Facades\Blade;
|
||||
|
@ -35,6 +37,7 @@ class AppServiceProvider extends ServiceProvider
|
|||
Notification::observe(NotificationObserver::class);
|
||||
StatusHashtag::observe(StatusHashtagObserver::class);
|
||||
User::observe(UserObserver::class);
|
||||
UserFilter::observe(UserFilterObserver::class);
|
||||
|
||||
Horizon::auth(function ($request) {
|
||||
return Auth::check() && $request->user()->is_admin;
|
||||
|
|
Loading…
Reference in a new issue