fix linter problems and loader test

This commit is contained in:
erogol committed 2020-02-13 17:23:37 +01:00
1 parent 2a78725b68
commit 0e35fdc2a1
3 files changed
+3 -8

No files matched your search

-3
View File
@@ -38,10 +38,7 @@ def text2phone(text, language):
if text[-1] == punctuations[-1]:
for punct in punctuations[:-1]:
ph = ph.replace('| |\n', '|'+punct+'| |', 1)
try:
ph = ph + punctuations[-1]
except:
print(text)
else:
for punct in punctuations:
ph = ph.replace('| |\n', '|'+punct+'| |', 1)