/** * Execute the console command. * * @return mixed */ public function handle() { $emails = Email::published()->unsent()->ready()->get(); foreach ($emails as $email) { $email->send(); $this->info("Sent email to " . $email->contact->email); } $this->info('Done Sending Emails'); }