summaryrefslogtreecommitdiffstats
path: root/users/models
diff options
context:
space:
mode:
authorAndrew Godwin2022-11-13 18:42:47 -0700
committerAndrew Godwin2022-11-13 18:43:09 -0700
commitddb3436275d3f02183f515c38cd3193cd1dfe2f4 (patch)
tree8902d4f085ad6d8323f43af20ca497d291e4d28a /users/models
parent68c156fd2758da5831bd83bfb1249dd014d78177 (diff)
downloadtakahe-ddb3436275d3f02183f515c38cd3193cd1dfe2f4.tar.gz
takahe-ddb3436275d3f02183f515c38cd3193cd1dfe2f4.tar.bz2
takahe-ddb3436275d3f02183f515c38cd3193cd1dfe2f4.zip
Boosting! Incoming, anyway.
Diffstat (limited to 'users/models')
-rw-r--r--users/models/inbox_message.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/users/models/inbox_message.py b/users/models/inbox_message.py
index 43424c9..6dbf5e8 100644
--- a/users/models/inbox_message.py
+++ b/users/models/inbox_message.py
@@ -12,12 +12,16 @@ class InboxMessageStates(StateGraph):
@classmethod
async def handle_received(cls, instance: "InboxMessage"):
- from activities.models import Post
+ from activities.models import Post, PostInteraction
from users.models import Follow
match instance.message_type:
case "follow":
await sync_to_async(Follow.handle_request_ap)(instance.message)
+ case "announce":
+ await sync_to_async(PostInteraction.handle_ap)(instance.message)
+ case "like":
+ await sync_to_async(PostInteraction.handle_ap)(instance.message)
case "create":
match instance.message_object_type:
case "note":