Fixed rendering of retweets of quoted tweets. Fixes #365

This commit is contained in:
2021-03-09 16:41:58 -06:00
parent 5b0b26799d
commit 45deae3402
3 changed files with 5 additions and 4 deletions

View File

@@ -25,7 +25,7 @@ def is_long(tweet):
returns True if a quote is detected, False otherwise."""
if hasattr(tweet, "quoted_status_id") and hasattr(tweet, "quoted_status"):
return tweet.quoted_status_id
elif hasattr(tweet, "retweeted_status") and hasattr(tweet, "quoted_status_id") and hasattr(tweet, "quoted_status"):
elif hasattr(tweet, "retweeted_status") and hasattr(tweet.retweeted_status, "quoted_status_id") and hasattr(tweet.retweeted_status, "quoted_status"):
return tweet.retweeted_status.quoted_status_id
return False