Fixes replies ap access

This commit is contained in:
Mouse Reeve 2020-02-17 21:58:02 -08:00
parent 5a3bc37bca
commit 0447fef279
2 changed files with 3 additions and 2 deletions

View file

@ -4,4 +4,4 @@ from .collection import get_outbox, get_outbox_page, get_add, get_remove, \
get_following, get_followers get_following, get_followers
from .create import get_create from .create import get_create
from .follow import get_follow_request, get_accept from .follow import get_follow_request, get_accept
from .status import get_review, get_status from .status import get_review, get_status, get_replies

View file

@ -136,6 +136,7 @@ def get_status(request, username, status_id):
@csrf_exempt @csrf_exempt
def get_replies(request, username, status_id): def get_replies(request, username, status_id):
''' ordered collection of replies to a status ''' ''' ordered collection of replies to a status '''
# TODO: this isn't a full implmentation
if request.method != 'GET': if request.method != 'GET':
return HttpResponseBadRequest() return HttpResponseBadRequest()
@ -147,7 +148,7 @@ def get_replies(request, username, status_id):
reply_parent=status reply_parent=status
).first() ).first()
replies_activity = activitypub.get_replies(status, replies) replies_activity = activitypub.get_replies(status, [replies])
return JsonResponse(replies_activity) return JsonResponse(replies_activity)