Skip to content

Commit

Permalink
fix: make "invexpense" optional with a smart default
Browse files Browse the repository at this point in the history
  • Loading branch information
redstreet committed Sep 23, 2023
1 parent 75a2d33 commit 7cc2ef3
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion beancount_reds_importers/libreader/ofxreader.py
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ def get_smart_date(self):

def vd(x): return x if x else datetime.date.min
return_date = max(*[vd(x) for x in dates])
print("Smart date computation. Dates were: ", dates)
# print("Smart date computation. Dates were: ", dates)

return return_date

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ def build_account_map(self):
"capgainsd_lt": self.config['capgainsd_lt'],
"capgainsd_st": self.config['capgainsd_st'],
"income": self.config['interest'],
"invexpense": self.config['invexpense'],
"invexpense": self.config.get('invexpense', "ACCOUNT_NOT_CONFIGURED:INVEXPENSE"),
}

if 'transfer' in self.config:
Expand Down

0 comments on commit 7cc2ef3

Please sign in to comment.