Skip to content

Commit 24537bf

Browse files
committed
add error handle
1 parent e0c6d36 commit 24537bf

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

inoreader/utils.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,10 @@ def extract_text(html_content):
3636
continue
3737

3838
link.text = '[%s](%s)' % (text, url)
39-
40-
return content.text_content().replace('\xa0', '').strip()
39+
try:
40+
return content.text_content().replace("\xa0", "").strip()
41+
except:
42+
return ""
4143

4244

4345
def download_image(url, path, filename, proxies=None):

0 commit comments

Comments
 (0)