diff --git a/account_reconcile_oca/models/account_bank_statement_line.py b/account_reconcile_oca/models/account_bank_statement_line.py index 17eda9dc6c..64c2cf2ce0 100644 --- a/account_reconcile_oca/models/account_bank_statement_line.py +++ b/account_reconcile_oca/models/account_bank_statement_line.py @@ -561,9 +561,9 @@ def _reconcile_bank_line_keep(self, data): def unreconcile_bank_line(self): self.ensure_one() - return getattr(self, "_unreconcile_bank_line_%s" % self.reconcile_mode)( - self.reconcile_data_info["data"] - ) + return getattr( + self, "_unreconcile_bank_line_%s" % (self.reconcile_mode or "edit") + )(self.reconcile_data_info["data"]) def _unreconcile_bank_line_edit(self, data): self.action_undo_reconciliation()