mirror of
https://github.com/fxsjy/jieba.git
synced 2025-07-10 00:01:33 +08:00
fix bug: load_userdict
This commit is contained in:
parent
a06b7d388e
commit
abcaf3e475
@ -332,8 +332,8 @@ def add_word(word, freq, tag=None):
|
||||
user_word_tag_tab[word] = tag
|
||||
for ch in xrange(len(word)):
|
||||
wfrag = word[:ch + 1]
|
||||
if wfrag not in lfreq:
|
||||
lfreq[wfrag] = 0
|
||||
if wfrag not in FREQ:
|
||||
FREQ[wfrag] = 0
|
||||
|
||||
__ref_cut = cut
|
||||
__ref_cut_for_search = cut_for_search
|
||||
|
Loading…
x
Reference in New Issue
Block a user