You've already forked JapariArchive
Updated code to use X account id instead of name. Updated dependencies
This commit is contained in:
@@ -92,7 +92,7 @@ async def UpdateMediaPosts(account : x_accounts, botData : RuntimeBotData) -> li
|
||||
posts = []
|
||||
|
||||
try:
|
||||
posts = [tweet async for tweet in botData.twApi.get_tweets(user_name = account.name, bottom_id = newest_post, all_posts = all_posts)]
|
||||
posts = [tweet async for tweet in botData.twApi.get_tweets(user_id = account.id, bottom_id = newest_post, all_posts = all_posts)]
|
||||
|
||||
except (UserProtected, UserNotFound) as ex:
|
||||
print("User dead: ", account.name, ex)
|
||||
@@ -108,7 +108,7 @@ async def DownloadAllMediaPosts(account : x_accounts, botData : RuntimeBotData)
|
||||
posts = []
|
||||
|
||||
try:
|
||||
async for tweet in botData.twApi.get_tweets(user_name = account.name, bottom_id = 1, all_posts = []):
|
||||
async for tweet in botData.twApi.get_tweets(user_id = account.id, bottom_id = 1, all_posts = []):
|
||||
if int(tweet.id) not in all_posts:
|
||||
posts.append(tweet)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user