Fix for auto-bill failure emails
This commit is contained in:
parent
a3f43a09e7
commit
3e035410dd
1 changed files with 2 additions and 1 deletions
|
|
@ -11,6 +11,7 @@ use App\Ninja\Datatables\PaymentDatatable;
|
|||
use App\Ninja\Repositories\AccountRepository;
|
||||
use App\Ninja\Repositories\PaymentRepository;
|
||||
use Auth;
|
||||
use App;
|
||||
use Exception;
|
||||
use Utils;
|
||||
|
||||
|
|
@ -141,7 +142,7 @@ class PaymentService extends BaseService
|
|||
$message = sprintf('%s: %s', ucwords($paymentDriver->providerName()), $exception->getMessage());
|
||||
//$message .= $exception->getTraceAsString();
|
||||
Utils::logError($message, 'PHP', true);
|
||||
if (! Auth::check()) {
|
||||
if (App::runningInConsole()) {
|
||||
$mailer = app('App\Ninja\Mailers\UserMailer');
|
||||
$mailer->sendMessage($invoice->user, $subject, $message, [
|
||||
'invoice' => $invoice
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue