Skip to content

Commit

Permalink
make transactionId optional, fixes #116
Browse files Browse the repository at this point in the history
  • Loading branch information
tarioch committed Oct 3, 2024
1 parent 4b3e52c commit 63acb15
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions src/tariochbctools/importers/nordigen/importer.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,9 +57,13 @@ def extract(self, file, existing_entries):
r.json()["transactions"]["booked"], key=lambda trx: trx["bookingDate"]
)
for trx in transactions:
metakv = {
"nordref": trx["transactionId"],
}
if "transactionId" in trx:
metakv = {
"nordref": trx["transactionId"],
}
else:
metakv = {}

if "creditorName" in trx:
metakv["creditorName"] = trx["creditorName"]
if "debtorName" in trx:
Expand Down

0 comments on commit 63acb15

Please sign in to comment.