diff --git a/account.py b/account.py index 86a0e784a5..bf8f12090d 100644 --- a/account.py +++ b/account.py @@ -57,7 +57,10 @@ class StatementImport(metaclass=PoolMeta): if not isinstance(ofx_account.statement, ofxparse.Statement): raise ImportStatementError( gettext('account_statement_ofx.msg_import_no_statement')) - statement.date = ofx_account.statement.balance_date.date() + try: + statement.date = ofx_account.statement.balance_date.date() + except AttributeError: + pass total_amount = sum( t.amount for t in ofx_account.statement.transactions) statement.total_amount = total_amount