summaryrefslogtreecommitdiff
path: root/httpd.c
diff options
context:
space:
mode:
authorGravatar Louis Brauer2024-05-27 12:24:17 +0200
committerGravatar Louis Brauer2024-05-27 12:24:17 +0200
commit81cf309e4d0ba6c2debccc21ea4f85e1e6245dc5 (patch)
tree10528a18c859964fa11eabe15955c85dce7ecf25 /httpd.c
parentUse enum instead of numeric status codes for HTTP statuses (diff)
downloadpenes-snac2-81cf309e4d0ba6c2debccc21ea4f85e1e6245dc5.tar.gz
penes-snac2-81cf309e4d0ba6c2debccc21ea4f85e1e6245dc5.tar.xz
penes-snac2-81cf309e4d0ba6c2debccc21ea4f85e1e6245dc5.zip
Implement Mastodon PATCH endpoint for account profile updates
Diffstat (limited to 'httpd.c')
-rw-r--r--httpd.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/httpd.c b/httpd.c
index 60afe28..1c60a56 100644
--- a/httpd.c
+++ b/httpd.c
@@ -362,6 +362,16 @@ void httpd_connection(FILE *f)
362 362
363 } 363 }
364 else 364 else
365 if (strcmp(method, "PATCH") == 0) {
366
367#ifndef NO_MASTODON_API
368 if (status == 0)
369 status = mastoapi_patch_handler(req, q_path,
370 payload, p_size, &body, &b_size, &ctype);
371#endif
372
373 }
374 else
365 if (strcmp(method, "OPTIONS") == 0) { 375 if (strcmp(method, "OPTIONS") == 0) {
366 status = HTTP_STATUS_OK; 376 status = HTTP_STATUS_OK;
367 } 377 }