From 77dddedae6d1a736e3d1e10c503c2075f82e2799 Mon Sep 17 00:00:00 2001 From: Untone Date: Mon, 5 Feb 2024 10:08:11 +0300 Subject: [PATCH] no-notify-on-entity-create --- resolvers/editor.py | 2 +- services/notify.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/resolvers/editor.py b/resolvers/editor.py index 62ea1110..59d313c8 100644 --- a/resolvers/editor.py +++ b/resolvers/editor.py @@ -81,7 +81,7 @@ async def create_shout(_, info, inp): reactions_follow(author.id, shout.id, True) # notifier - await notify_shout(shout_dict, 'create') + # await notify_shout(shout_dict, 'create') return {'shout': shout_dict} diff --git a/services/notify.py b/services/notify.py index 597835b5..588c1eee 100644 --- a/services/notify.py +++ b/services/notify.py @@ -12,7 +12,7 @@ async def notify_reaction(reaction, action: str = 'create'): print(f'[services.notify] Failed to publish to channel {channel_name}: {e}') -async def notify_shout(shout, action: str = 'create'): +async def notify_shout(shout, action: str = 'update'): channel_name = 'shout' data = {'payload': shout, 'action': action} try: