Skip to content

Commit

Permalink
Merge pull request #42419 from barredterra/si-initial-value
Browse files Browse the repository at this point in the history
  • Loading branch information
barredterra authored Jul 22, 2024
2 parents be26482 + 65f80ab commit bf2c9a7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion erpnext/accounts/doctype/sales_invoice/sales_invoice.js
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ erpnext.accounts.SalesInvoiceController = class SalesInvoiceController extends (

const payment_is_overdue = doc.payment_schedule
.map((row) => Date.parse(row.due_date) < Date.now())
.reduce((prev, current) => prev || current);
.reduce((prev, current) => prev || current, false);

if (payment_is_overdue) {
this.frm.add_custom_button(
Expand Down

0 comments on commit bf2c9a7

Please sign in to comment.