Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
squidgetx committed Jan 10, 2023
1 parent 4d0d305 commit e616e52
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion server/db/scraper.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ function parse_tweet(tweet) {
tweet.referenced_tweet_id = tweet.referenced_tweets[0].id;
// TODO what if there are more than 1 referenced tweet? is that even possible
}
if ("attachments" in tweet) {
if ("attachments" in tweet && tweet.attachments.media_keys) {
tweet.media_id_1 = tweet.attachments.media_keys[0];
tweet.media_id_2 = tweet.attachments.media_keys[1];
// TODO log if > 1 media key
Expand Down

0 comments on commit e616e52

Please sign in to comment.