author-user-fix
All checks were successful
Deploy on push / deploy (push) Successful in 6s

This commit is contained in:
2025-05-29 12:15:06 +03:00
parent 6c0d96e7ac
commit d4c16658bd
2 changed files with 9 additions and 10 deletions

View File

@@ -252,11 +252,11 @@ async def invalidate_authors_cache(author_id=None):
f"author:follows-shouts:{author_id}",
]
# Получаем user_id автора, если есть
# Получаем author_id автора, если есть
with local_session() as session:
author = session.query(Author).filter(Author.id == author_id).first()
if author and Author.id:
specific_keys.append(f"author:user:{Author.id.strip()}")
specific_keys.append(f"author:id:{Author.id}")
# Удаляем конкретные ключи
for key in specific_keys: