mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-07 10:14:46 -04:00
Bloomberg -fixed double words.
when hyperlinks are present the words are duplicated in text.
This commit is contained in:
parent
e54bad7471
commit
2e2c700fe5
@ -154,12 +154,12 @@ class Bloomberg(BasicNewsRecipe):
|
||||
|
||||
if item['type'] == 'entity':
|
||||
if item['content'] and item['content'][0] and item['content'][0]['value']:
|
||||
if item['subType'] == 'person' or 'security':
|
||||
body += item['content'][0]['value']
|
||||
if item['subType'] == 'story':
|
||||
if item['data'] and item['data']['link'] and item['data']['link']['destination']:
|
||||
if 'web' in item['data']['link']['destination']:
|
||||
body += '<a href="' + item['data']['link']['destination']['web'] + '">' + item['content'][0]['value'] + '</a>'
|
||||
elif item['subType'] == 'person' or 'security':
|
||||
body += item['content'][0]['value']
|
||||
|
||||
if objects['type'] == 'quote':
|
||||
if 'content' not in objects:
|
||||
|
@ -148,12 +148,12 @@ class Bloomberg(BasicNewsRecipe):
|
||||
|
||||
if item['type'] == 'entity':
|
||||
if item['content'] and item['content'][0] and item['content'][0]['value']:
|
||||
if item['subType'] == 'person' or 'security':
|
||||
body += item['content'][0]['value']
|
||||
if item['subType'] == 'story':
|
||||
if item['data'] and item['data']['link'] and item['data']['link']['destination']:
|
||||
if 'web' in item['data']['link']['destination']:
|
||||
body += '<a href="' + item['data']['link']['destination']['web'] + '">' + item['content'][0]['value'] + '</a>'
|
||||
elif item['subType'] == 'person' or 'security':
|
||||
body += item['content'][0]['value']
|
||||
|
||||
if objects['type'] == 'quote':
|
||||
if 'content' not in objects:
|
||||
|
Loading…
x
Reference in New Issue
Block a user