1

I'm trying to send a delayed message but it's not working, it gets into the jobs table but it stays there. Here is my code:

Mail::later(5, 'emails.test', ['testVar' => 'hello'], function ($message){
   $message->to('*someaddress@hotmail.com', 'Someone');
   $message->subject('Subject');        
});

*: i use a real address

emails.test:

<p>  This is a test, an email test. </p>

.env:

QUEUE_DRIVER=database

When i use send instead of later, the message is sent perfectly.

Do i have to modify something more to get this to work?

Erick Ramírez
  • 75
  • 2
  • 14

1 Answers1

0

I was not using this command to run the queue listener: php artisan queue:listen. Now it is working good. Thank you, nathanmac

Community
  • 1
  • 1
Erick Ramírez
  • 75
  • 2
  • 14