Commit 3314a1df authored by Michal Čihař's avatar Michal Čihař

Wrap too long condition

parent 08747f97
......@@ -407,7 +407,9 @@ class UnitManager(models.Manager):
cnt = len(terms)
# Try to find at least configured number of similar strings,
# remove up to 4 words
while len(ret) < appsettings.SIMILAR_MESSAGES and cnt > 0 and len(terms) - cnt < 4:
while (len(ret) < appsettings.SIMILAR_MESSAGES
and cnt > 0
and len(terms) - cnt < 4):
for search in itertools.combinations(terms, cnt):
results = self.search(
' '.join(search),
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment