jsongix
Some checks failed
Deploy on push / deploy (push) Failing after 10s

This commit is contained in:
Untone 2024-10-31 15:28:41 +03:00
parent 6dd6fd764a
commit 42e06bd2e6

View File

@ -265,7 +265,7 @@ def get_shouts_with_stats(q, limit=20, offset=0, author_id=None):
captions = {int(ca['author_id']): ca['caption'] for ca in captions_json} if captions_json else {} captions = {int(ca['author_id']): ca['caption'] for ca in captions_json} if captions_json else {}
authors = [a for a in authors_json] if authors_json else [] authors = [a for a in authors_json] if authors_json else []
for author in authors: for author in authors:
author['caption'] = captions.get(int(author.id), "") author['caption'] = captions.get(int(author['id']), "")
shout.authors = authors shout.authors = authors
topics = [t for t in topics_json] if topics_json else [] topics = [t for t in topics_json] if topics_json else []
for topic in topics: for topic in topics: