Yaron Koresh commited on
Commit
481ff40
·
verified ·
1 Parent(s): f487489

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -71,7 +71,7 @@ def translate(text,lang):
71
  translated = text
72
 
73
  try:
74
- src_lang = html.xpath('//span[@class="source-language"]')[0].text_content().strip()
75
  trgt_lang = html.xpath('//span[@class="target-language"]')[0].text_content().strip()
76
  src_text = html.xpath('//pre[@id="tw-source-text"]/span')[0].text_content().strip()
77
  trgt_text = html.xpath('//pre[@id="tw-target-text"]/span')[0].text_content().strip()
 
71
  translated = text
72
 
73
  try:
74
+ src_lang = html.xpath('//span[@class="source-language"]/span')[0].text_content().strip()
75
  trgt_lang = html.xpath('//span[@class="target-language"]')[0].text_content().strip()
76
  src_text = html.xpath('//pre[@id="tw-source-text"]/span')[0].text_content().strip()
77
  trgt_text = html.xpath('//pre[@id="tw-target-text"]/span')[0].text_content().strip()