Skip to content

Commit c9dc296

Browse files
committed
Fixed countCustomerInvoices method
1 parent 47f3041 commit c9dc296

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Infrastructure/Repository/ArrayDatasetRepository.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -76,8 +76,8 @@ public function countCustomerInvoices(string $customerId): int
7676
$invoices = [];
7777

7878
foreach ($this->dataset as $row) {
79-
if ($row->customerId === $customerId && !in_array($row->invoiceDate, $invoices)) {
80-
$invoices[] = $row->invoiceDate;
79+
if ($row->customerId === $customerId && !in_array($row->invoiceNo, $invoices)) {
80+
$invoices[] = $row->invoiceNo;
8181
}
8282
}
8383

0 commit comments

Comments
 (0)