1
0

add japanese, fix utf8

This commit is contained in:
ThomasV
2014-09-03 17:21:43 +02:00
parent b32fbd210c
commit 1e75d6f854
2 changed files with 4 additions and 2 deletions

View File

@@ -37,6 +37,8 @@ class Mnemonic(object):
filename = 'english.txt'
elif lang[0:2] == 'pt':
filename = 'portuguese.txt'
elif lang[0:2] == 'ja':
filename = 'japanese.txt'
else:
filename = 'english.txt'
@@ -48,7 +50,7 @@ class Mnemonic(object):
line = line.strip(' \r')
assert ' ' not in line
if line:
self.wordlist.append(line)
self.wordlist.append(line.decode('utf8'))
print_error("wordlist has %d words"%len(self.wordlist))
@classmethod