mirror of
https://github.com/openclassify/openclassify.git
synced 2026-01-11 18:01:10 -06:00
#3611 igam notification
This commit is contained in:
parent
2267339c91
commit
de79acb2dc
@ -0,0 +1,9 @@
|
||||
<?php namespace Visiosoft\ProfileModule\Events;
|
||||
|
||||
class PasswordChanged
|
||||
{
|
||||
public function __construct()
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
@ -5,6 +5,7 @@ use Anomaly\UsersModule\User\User;
|
||||
use Anomaly\UsersModule\User\UserPassword;
|
||||
use Illuminate\Support\Facades\Auth;
|
||||
use Illuminate\Support\Facades\Hash;
|
||||
use Visiosoft\ProfileModule\Events\PasswordChanged;
|
||||
|
||||
class PasswordFormHandler
|
||||
{
|
||||
@ -43,6 +44,9 @@ class PasswordFormHandler
|
||||
$user = User::query()->find(Auth::id());
|
||||
$user->setAttribute('password', $builder->getPostValue('new_password'));
|
||||
$user->save($user->toArray());
|
||||
|
||||
event(new PasswordChanged());
|
||||
|
||||
$messages->success(trans('visiosoft.module.profile::message.your_password_changed'));
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user