I am trying to call event() in such way as shown below.
event(new User($user));
But it returns me Error: Call to undefined function Modules\User\Http\Controllers\API\event() in file /var/www/Modules/User/Http/Controllers/API/UserController.php on line 156
I found that the event function missing in Illuminate\Foundation\helpers.php
Yeah, i don't really modify files in the vendor directory. But after composer update it looks fine. But then event() function didn't trigger any job of mine.