Reputation: 79
As the title itself says, I've got the following issue:
Target [Illuminate\Contracts\Bus\Dispatcher] is not instantiable.
.
I'm trying to use a custom script and include the default Laravel classes
require_once dirname(__DIR__) . '/vendor/autoload.php';
require_once dirname(__DIR__) . '/bootstrap/app.php';
use App\Mail\ChangeInStatusMail;
use App\Jobs\SendEmail;
After using SendEmail::dispatch() I get the previously mentioned error. Any ideas?
Upvotes: 4
Views: 4028
Reputation: 1061
Since I have experience of updating from laravel 5.2 to 5.8 or so, I had to replace 'Collective\Bus\BusServiceProvider
', with 'Illuminate\Bus\BusServiceProvider
', in providers array in config/app.php.
This worked for me and the error no more appeared on Password reset link click
Upvotes: 1