summaryrefslogtreecommitdiff
path: root/activitypub.c
diff options
context:
space:
mode:
Diffstat (limited to 'activitypub.c')
-rw-r--r--activitypub.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/activitypub.c b/activitypub.c
index 2e11a82..d792ce2 100644
--- a/activitypub.c
+++ b/activitypub.c
@@ -506,9 +506,12 @@ int activitypub_get_handler(d_char *req, char *q_path,
506 506
507 p_path = xs_list_get(l, 2); 507 p_path = xs_list_get(l, 2);
508 508
509 *ctype = "application/activity+json";
510
509 if (p_path == NULL) { 511 if (p_path == NULL) {
510 /* if there was no component after the user, it's an actor request */ 512 /* if there was no component after the user, it's an actor request */
511 msg = msg_actor(&snac); 513 msg = msg_actor(&snac);
514 *ctype = "application/ld+json";
512 } 515 }
513 else 516 else
514 if (strcmp(p_path, "outbox") == 0) { 517 if (strcmp(p_path, "outbox") == 0) {
@@ -532,7 +535,6 @@ int activitypub_get_handler(d_char *req, char *q_path,
532 if (status == 200 && msg != NULL) { 535 if (status == 200 && msg != NULL) {
533 *body = xs_json_dumps_pp(msg, 4); 536 *body = xs_json_dumps_pp(msg, 4);
534 *b_size = strlen(*body); 537 *b_size = strlen(*body);
535 *ctype = "application/activity+json";
536 } 538 }
537 539
538 user_free(&snac); 540 user_free(&snac);