limit smart hint length
This commit is contained in:
parent
9a889c6866
commit
beba5a3d6c
@ -1046,7 +1046,8 @@ class WordHinter:
|
|||||||
match = re.search('[A-Za-z]{3,}', candidate)
|
match = re.search('[A-Za-z]{3,}', candidate)
|
||||||
if not match:
|
if not match:
|
||||||
continue
|
continue
|
||||||
if match.end() - match.start() < 4:
|
length = match.end() - match.start()
|
||||||
|
if 4 > length or length > 8:
|
||||||
continue
|
continue
|
||||||
yield candidate[match.start():match.end()].lower()
|
yield candidate[match.start():match.end()].lower()
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user