We don't want this to call .error() for legit logs already completed

This commit is contained in:
Alexandre Aubin 2019-10-14 20:28:16 +02:00
parent ce1cabc680
commit 61931f2c4b

View file

@ -502,6 +502,9 @@ class OperationLogger(object):
The missing of the message below could help to see an electrical
shortage.
"""
if self.ended_at is not None or self.started_at is None:
return
else:
self.error(m18n.n('log_operation_unit_unclosed_properly'))