This commit is contained in:
parent
a7f163009e
commit
61c7f5a0dc
|
@ -50,8 +50,12 @@ async def get_my_shout(_, info, shout_id: int):
|
||||||
@query.field("get_shouts_drafts")
|
@query.field("get_shouts_drafts")
|
||||||
@login_required
|
@login_required
|
||||||
async def get_shouts_drafts(_, info):
|
async def get_shouts_drafts(_, info):
|
||||||
info.context.get("user_id")
|
# user_id = info.context.get("user_id")
|
||||||
author_dict = info.context["author"]
|
author_dict = info.context.get("author")
|
||||||
|
if not author_dict:
|
||||||
|
logger.error("trying to get drafts failed")
|
||||||
|
logger.debug(info)
|
||||||
|
return []
|
||||||
author_id = author_dict.get("id")
|
author_id = author_dict.get("id")
|
||||||
shouts = []
|
shouts = []
|
||||||
with local_session() as session:
|
with local_session() as session:
|
||||||
|
|
Loading…
Reference in New Issue
Block a user