Skip to content

Instantly share code, notes, and snippets.

@tbergeron
Created March 21, 2014 20:30
Show Gist options
  • Save tbergeron/9695712 to your computer and use it in GitHub Desktop.
Save tbergeron/9695712 to your computer and use it in GitHub Desktop.
private function sendWelcomeEmail(User $user)
{
// Enabling pretend mode for developers
// Writing email in logs instead of really sending them.
if (App::environment('development')) {
Mail::pretend();
}
$data = [];
Mail::queue('success_email', $data, function($message)
{
$message->to($user->email, $user->firstname . ' ' . $user->lastname);
});
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment