From 516945ddecbad48307f2a2e3dd20d84a2775c898 Mon Sep 17 00:00:00 2001 From: Untone Date: Fri, 2 Feb 2024 21:04:21 +0300 Subject: [PATCH] publish-fix --- resolvers/editor.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/resolvers/editor.py b/resolvers/editor.py index 839eba59..9391b692 100644 --- a/resolvers/editor.py +++ b/resolvers/editor.py @@ -153,6 +153,8 @@ async def update_shout( # noqa: C901 # Replace datetime with Unix timestamp shout_input['updated_at'] = current_time # Set updated_at as Unix timestamp + if publish: + shout_input['published_at'] = current_time Shout.update(shout, shout_input) session.add(shout)