Skip to content

Commit

Permalink
don't try/except
Browse files Browse the repository at this point in the history
  • Loading branch information
warmlogic committed Mar 29, 2021
1 parent a85de93 commit 9273b6c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions utils/tweet_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -140,9 +140,9 @@ def get_tweet_info(status: Dict) -> Dict:
place_country_code = status['place'].get('country_code')
# Possible place_type values: country, admin, city, neighborhood, poi
place_type = status['place'].get('place_type')
try:
if 'extended_tweet' in status:
media_urls = get_media_urls(status['extended_tweet'])
except KeyError:
else:
media_urls = get_media_urls(status)

tweet_info = TweetInfo(
Expand Down

0 comments on commit 9273b6c

Please sign in to comment.