mirror of
https://github.com/Bubka/2FAuth.git
synced 2025-08-18 17:38:20 +02:00
Control & Promote administrator status via a method rather than a prop
This commit is contained in:
@@ -63,7 +63,7 @@ class RemoteUserProvider implements UserProvider
|
||||
Log::info(sprintf('Remote user %s created with email address %s', var_export($user->name, true), var_export($user->email, true)));
|
||||
|
||||
if (User::count() === 1) {
|
||||
$user->is_admin = true;
|
||||
$user->promoteToAdministrator();
|
||||
$user->save();
|
||||
}
|
||||
} else {
|
||||
|
Reference in New Issue
Block a user