Fix exception in AccountingInvoiceAdd
This commit is contained in:
parent
c1bb20dec0
commit
8f283f83f2
@ -49,7 +49,7 @@ class AccountingInvoiceAdd extends Command
|
|||||||
|
|
||||||
// Check the customer exists
|
// Check the customer exists
|
||||||
if ($o->account->providers->where('pivot.provider_oauth_id',$so->id)->count() !== 1)
|
if ($o->account->providers->where('pivot.provider_oauth_id',$so->id)->count() !== 1)
|
||||||
throw new \Exception('Account [%d] for Invoice [%d] not defined',$o->account_id,$o->id);
|
throw new \Exception(sprintf('Account [%d] for Invoice [%d] not defined',$o->account_id,$o->id));
|
||||||
|
|
||||||
$ao = $o->account->providers->where('pivot.provider_oauth_id',$so->id)->pop();
|
$ao = $o->account->providers->where('pivot.provider_oauth_id',$so->id)->pop();
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user