feat: exclude reblogs from fetched tagged statuses

This commit is contained in:
Ayo Ayco 2025-01-18 20:09:06 +01:00
parent 6246445adb
commit 5e647e559e

View file

@ -5,10 +5,13 @@ from . import utils
def get_account_tagged_statuses(app, tag): def get_account_tagged_statuses(app, tag):
mastodon = initialize_client(app) mastodon = initialize_client(app)
account = mastodon.me() account = mastodon.me()
print('>>> account id', account.id)
statuses = [] statuses = []
try: try:
statuses = mastodon.account_statuses(id=account.id, tagged=tag) statuses = mastodon.account_statuses(
id=account.id,
tagged=tag,
exclude_reblogs=True
)
except: except:
print('>>> failed to fetch statuses', tag) print('>>> failed to fetch statuses', tag)