fix bug in batch SimpleFIN startDate logic (#504)

This commit is contained in:
Matt Fiddaman
2024-11-21 15:49:08 +00:00
committed by GitHub
parent b1bf7ee7cd
commit 30f21497a6
2 changed files with 10 additions and 3 deletions

View File

@@ -210,12 +210,13 @@ function getAccountResponse(results, accountId, startDate) {
dateToUse = trans.posted;
}
newTrans.bookingDate = getDate(new Date(dateToUse * 1000));
if (newTrans.bookingDate < startDate) {
const transactionDate = new Date(dateToUse * 1000);
if (transactionDate < startDate) {
continue;
}
newTrans.date = newTrans.bookingDate;
newTrans.date = getDate(transactionDate);
newTrans.payeeName = trans.payee;
newTrans.remittanceInformationUnstructured = trans.description;
newTrans.transactionAmount = { amount: trans.amount, currency: 'USD' };

View File

@@ -0,0 +1,6 @@
---
category: Bugfix
authors: [matt-fidd]
---
Fix bug in batch SimpleFIN startDate logic