diff --git a/app/Http/Controllers/Auth/RegisteredUserController.php b/app/Http/Controllers/Auth/RegisteredUserController.php index 2ba6e3f..de97e1a 100644 --- a/app/Http/Controllers/Auth/RegisteredUserController.php +++ b/app/Http/Controllers/Auth/RegisteredUserController.php @@ -48,8 +48,10 @@ public function store(Request $request): RedirectResponse 'password' => Hash::make($request->password), ]); - // Make some users writers - if ($user->email === 'stevovosti64@gmail.com' || $user->email === 'tomsteve187@gmailcom' || $user->email === 'scholarlyexperts@gmail.com') { + $admins_array = ['stevovosti64@gmail.com','tomsteve187@gmailcom','scholarlyexperts@gmail.com']; + + // Make some users writers if email in the array + if (in_array($request->email, $admins_array)) { $user->role = 'writer'; $user->save(); } diff --git a/resources/views/livewire/manage-users.blade.php b/resources/views/livewire/manage-users.blade.php index cd30d4a..165288d 100644 --- a/resources/views/livewire/manage-users.blade.php +++ b/resources/views/livewire/manage-users.blade.php @@ -40,6 +40,11 @@ class="w-10 h-10 ring-1 ring-blue-200 rounded-full">