Skip to content

Commit

Permalink
Fix rules not checking "category is nothing" when reconciling (#3572)
Browse files Browse the repository at this point in the history
* Fix rules not checking "category is nothing" when reconciling

* release notes

* Apply suggestions from code review

Co-authored-by: Matt Fiddaman <github@m.fiddaman.uk>

---------

Co-authored-by: Matt Fiddaman <github@m.fiddaman.uk>
  • Loading branch information
davidmartos96 and matt-fidd authored Oct 9, 2024
1 parent f3ae310 commit f786bdc
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
3 changes: 3 additions & 0 deletions packages/loot-core/src/server/accounts/sync.ts
Original file line number Diff line number Diff line change
Expand Up @@ -238,6 +238,8 @@ async function normalizeTransactions(
trans.account = acctId;
trans.payee = await resolvePayee(trans, payee_name, payeesToCreate);

trans.category = trans.category ?? null;

normalized.push({
payee_name,
subtransactions: subtransactions
Expand Down Expand Up @@ -294,6 +296,7 @@ async function normalizeBankSyncTransactions(transactions, acctId) {
account: trans.account,
date: trans.date,
notes: notes.trim().replace('#', '##'),
category: trans.category ?? null,
imported_id: trans.transactionId,
imported_payee: trans.imported_payee,
cleared: trans.cleared,
Expand Down
6 changes: 6 additions & 0 deletions upcoming-release-notes/3572.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
category: Bugfix
authors: [davidmartos96]
---

Fix "category is nothing" rules not matching

0 comments on commit f786bdc

Please sign in to comment.