Commit 65ea42c1 authored by Scott Weldon's avatar Scott Weldon

Prevent null object dereference

`self.lgr` can be `None`, particularly during tests.
parent a4e02a4b
...@@ -312,7 +312,7 @@ class OfxConverter(Converter): ...@@ -312,7 +312,7 @@ class OfxConverter(Converter):
if (hasattr(txn, 'tferaction') and txn.tferaction is not None): if (hasattr(txn, 'tferaction') and txn.tferaction is not None):
tferaction = txn.tferaction.lower() tferaction = txn.tferaction.lower()
if payee != "": if payee != "" and self.lgr is not None:
payee = self.lgr.get_autosync_payee(payee, self.name) payee = self.lgr.get_autosync_payee(payee, self.name)
payee_format = self.payee_format payee_format = self.payee_format
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment