mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2024-11-08 20:22:42 +01:00
Fix for multiple email accounts
This commit is contained in:
parent
7459d516cf
commit
d44834d5ee
@ -79,7 +79,13 @@ class Mailer
|
||||
config(['mail.' . $field => $value]);
|
||||
}
|
||||
}
|
||||
(new \Illuminate\Mail\MailServiceProvider(app()))->register();
|
||||
|
||||
$app = \App::getInstance();
|
||||
$app->singleton('swift.transport', function ($app) {
|
||||
return new \Illuminate\Mail\TransportManager($app);
|
||||
});
|
||||
$mailer = new \Swift_Mailer($app['swift.transport']->driver());
|
||||
Mail::setSwiftMailer($mailer);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user