diff --git a/account.py b/account.py index 783cc532d4..44691fa852 100644 --- a/account.py +++ b/account.py @@ -204,6 +204,8 @@ class AccountFrFEC(Wizard): ('company', '=', company.id), ]) fiscalyear_ids = list(map(int, fiscalyears)) + if not fiscalyear_ids: + return query = (account .join(line, condition=line.account == account.id)