Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion utils/twitterbot.py
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,11 @@ def make_follow_for_current_account(account_screen_name, limit):
api.create_friendship(tw_user.id)
tweets = tw_user.timeline()[:2] # get 2 tweets for like
for tweet in tweets:
api.create_favorite(tweet.id)
if not tweet.in_reply_to_status_id and (
tweet.lang == 'en' and not tweet.in_reply_to_user_id):
api.create_favorite(tweet.id)
else:
continue

except tweepy.error.TweepError as err:
if err.api_code == 161:
Expand Down