mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-07-09 03:14:30 -04:00
Workaround for auto-bill w/archived user
This commit is contained in:
parent
303e17f6af
commit
a11cf02463
@ -150,6 +150,13 @@ class SendRecurringInvoices extends Command
|
||||
|
||||
if ($invoice->getAutoBillEnabled() && $invoice->client->autoBillLater()) {
|
||||
$this->info('Processing Autobill-delayed Invoice: ' . $invoice->id);
|
||||
|
||||
// TODO don't skip
|
||||
if ($invoice->user->trashed()) {
|
||||
$this->info('Archived user: skipping');
|
||||
continue;
|
||||
}
|
||||
|
||||
Auth::loginUsingId($invoice->user_id);
|
||||
$this->paymentService->autoBillInvoice($invoice);
|
||||
Auth::logout();
|
||||
|
Loading…
x
Reference in New Issue
Block a user