mirror of
https://github.com/OCA/account-reconcile.git
synced 2025-01-20 12:27:39 +02:00
[FIX] dead error management code
This commit is contained in:
@@ -406,21 +406,13 @@ class AccountStatementLine(orm.Model):
|
||||
"""
|
||||
profile_obj = self.pool.get('account.statement.profile')
|
||||
res = {}
|
||||
errors_stack = []
|
||||
if line.get('already_completed'):
|
||||
return res
|
||||
try:
|
||||
# Ask the rule
|
||||
vals = profile_obj._find_values_from_rules(cr, uid, rules, line, context)
|
||||
if vals:
|
||||
vals['id'] = line['id']
|
||||
return vals
|
||||
except ErrorTooManyPartner as exc:
|
||||
msg = "Line ID %s had following error: %s" % (line['id'], exc.value)
|
||||
errors_stack.append(msg)
|
||||
if errors_stack:
|
||||
msg = u"\n".join(errors_stack)
|
||||
raise ErrorTooManyPartner(msg)
|
||||
return res
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user