From 28864f6ddcaebd4ab41787f61a2ee03056d255bd Mon Sep 17 00:00:00 2001 From: Unai Beristain Date: Wed, 11 Dec 2024 11:14:34 +0100 Subject: [PATCH] [IMP] mgmtsystem_audit: Improve Expected singleton error --- mgmtsystem_audit/models/mgmtsystem_audit.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mgmtsystem_audit/models/mgmtsystem_audit.py b/mgmtsystem_audit/models/mgmtsystem_audit.py index 92850b9f9c82..33ea1deb8ddd 100644 --- a/mgmtsystem_audit/models/mgmtsystem_audit.py +++ b/mgmtsystem_audit/models/mgmtsystem_audit.py @@ -92,7 +92,7 @@ class MgmtsystemAudit(models.Model): def _compute_number_of_nonconformities(self): """Count number of nonconformities.""" for audit in self: - audit.number_of_nonconformities = len(self.nonconformity_ids) + audit.number_of_nonconformities = len(audit.nonconformity_ids) @api.depends("imp_opp_ids") def _compute_number_of_improvement_opportunities(self):