i want to get email notification each time a new user is registered but after creating php artisan make:notification Taskcompleted
and added Notification::route('mail','admin@gmail.com')->notify(new TaskCompleted());
like this in my contoller
public function store(Request $request){
$employee = request()->validate([
'employee_id' => 'required|max:250',
'name' => 'required|max:100',
'place_of_birth' => 'nullable|max:100',]);
Notification::route('mail','admin@gmail.com')->notify(new TaskCompleted());
i keep getting this error Trying to access array offset on value of type null
i have imported the necessary class and configured my .env file with mailtrap,still yet same error
via Chebli Mohamed
Aucun commentaire:
Enregistrer un commentaire