Remove hyphens ("-") from terms to avoid hashtags terminating early

This commit is contained in:
Steinar Bang
2020-07-11 07:04:06 +01:00
parent 8749618a8a
commit 45897295d1

View File

@ -65,7 +65,7 @@ def get_feed(feed_url, last_update):
def get_entry(entry):
hashtags = []
for tag in entry.get('tags', []):
t = tag['term'].replace(' ', '_').replace('.', '')
t = tag['term'].replace(' ', '_').replace('.', '').replace('-', '')
hashtags.append('#{}'.format(t))
return {
'url': entry.id,