Tomás F commited on
Commit
460a4e3
1 Parent(s): 159f1cd

Only show images if available

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -77,7 +77,7 @@ with st.spinner('⚙️ Analysing articles...'):
77
  st.sidebar.metric("Negative", f"👎 {sentiment_distribution.get('negative'):.2f}%")
78
 
79
  for article, sentiment in filter_with_sentiment(classified_articles, target_sentiments):
80
- if media_contet in article:
81
  img_url = article.media_content[0].get('url')
82
  st.image(img_url, width=300)
83
 
 
77
  st.sidebar.metric("Negative", f"👎 {sentiment_distribution.get('negative'):.2f}%")
78
 
79
  for article, sentiment in filter_with_sentiment(classified_articles, target_sentiments):
80
+ if 'media_content' in article:
81
  img_url = article.media_content[0].get('url')
82
  st.image(img_url, width=300)
83