From ec88d84775874a1d433cebecbad1b9165f7f0d04 Mon Sep 17 00:00:00 2001 From: rimu <3310831+rimu@users.noreply.github.com> Date: Fri, 3 May 2024 06:27:25 +1200 Subject: [PATCH] add celery decorator to task functions #172 --- app/activitypub/routes.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/app/activitypub/routes.py b/app/activitypub/routes.py index 99d5a55b..22663bc2 100644 --- a/app/activitypub/routes.py +++ b/app/activitypub/routes.py @@ -1245,6 +1245,7 @@ def user_inbox(actor): return resp +@celery.task def process_user_follow_request(request_json, activitypublog_id, remote_user_id): activity_log = ActivityPubLog.query.get(activitypublog_id) local_user_ap_id = request_json['object'] @@ -1285,6 +1286,7 @@ def process_user_follow_request(request_json, activitypublog_id, remote_user_id) db.session.commit() +@celery.task def process_user_undo_follow_request(request_json, activitypublog_id, remote_user_id): activity_log = ActivityPubLog.query.get(activitypublog_id) local_user_ap_id = request_json['object']['object']