mirror of
https://github.com/MrUnknownDE/panel.git
synced 2026-04-18 22:33:44 +02:00
Fix user password handling in Admin CP
This commit is contained in:
@@ -58,8 +58,10 @@ class UserUpdateService
|
||||
*/
|
||||
public function handle(User $user, array $data): Collection
|
||||
{
|
||||
if (array_has($data, 'password')) {
|
||||
if (! empty(array_get($data, 'password'))) {
|
||||
$data['password'] = $this->hasher->make($data['password']);
|
||||
} else {
|
||||
unset($data['password']);
|
||||
}
|
||||
|
||||
if ($this->isUserLevel(User::USER_LEVEL_ADMIN)) {
|
||||
|
||||
Reference in New Issue
Block a user