From cfcb858bbaefb3e117b96173419ac1bce7378a83 Mon Sep 17 00:00:00 2001 From: Untone Date: Tue, 7 May 2024 19:17:18 +0300 Subject: [PATCH] new-profile-followers --- resolvers/author.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/resolvers/author.py b/resolvers/author.py index 6da5dc23..76901952 100644 --- a/resolvers/author.py +++ b/resolvers/author.py @@ -179,8 +179,8 @@ async def get_author_follows(_, _info, slug="", user=None, author_id=0): author_query = author_query.filter(Author.id == author_id) else: raise ValueError("One of slug, user, or author_id must be provided") - [result] = local_session().execute(author_query) - if len(result) > 0: + result = local_session().execute(author_query) + if result: # logger.debug(result) [author] = result # logger.debug(author)