diff options
author | Andrew Godwin | 2022-12-16 21:32:08 -0700 |
---|---|---|
committer | Andrew Godwin | 2022-12-16 21:32:08 -0700 |
commit | cc3c3d98168801e744d068f68da34e9b125e24fb (patch) | |
tree | 22cece10e2f2de593c4b8354a00fcb98cb515f53 /activities/views | |
parent | 23a3f7e9d2d9f149e6f9aab1f122d40825e9014d (diff) | |
download | takahe-cc3c3d98168801e744d068f68da34e9b125e24fb.tar.gz takahe-cc3c3d98168801e744d068f68da34e9b125e24fb.tar.bz2 takahe-cc3c3d98168801e744d068f68da34e9b125e24fb.zip |
404 deleted posts
Diffstat (limited to 'activities/views')
-rw-r--r-- | activities/views/posts.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/activities/views/posts.py b/activities/views/posts.py index a3810e0..b543535 100644 --- a/activities/views/posts.py +++ b/activities/views/posts.py @@ -27,6 +27,8 @@ class Individual(TemplateView): if self.identity.blocked: raise Http404("Blocked user") self.post_obj = get_object_or_404(self.identity.posts, pk=post_id) + if self.post_obj.state in [PostStates.deleted, PostStates.deleted_fanned_out]: + raise Http404("Deleted post") # If they're coming in looking for JSON, they want the actor if request.ap_json: # Return post JSON |