Skip to content

Commit

Permalink
Invoice item - fix offset
Browse files Browse the repository at this point in the history
  • Loading branch information
janbarasek committed Feb 3, 2022
1 parent 2e1e2b8 commit 8133c48
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/InvoiceManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ public function createInvoice(OrderInterface $order): Invoice
$invoiceItem = $this->invoiceRepository->getByOrder($order);
if ($invoiceItem !== []) {
/** @var Invoice $invoice */
$invoice = $invoiceItem;
$invoice = $invoiceItem[0];
$invoice->setPrice($order->getPrice());
} else {
assert($order instanceof Order);
Expand Down

0 comments on commit 8133c48

Please sign in to comment.