summaryrefslogtreecommitdiff
path: root/httpd.c
diff options
context:
space:
mode:
authorgrunfink <grunfink@noreply.codeberg.org>2024-01-11 17:46:15 +0000
committergrunfink <grunfink@noreply.codeberg.org>2024-01-11 17:46:15 +0000
commit285fb589ff1727e61144f17f77cf275c3a5905ce (patch)
tree683be057b3f1b659648e0fdecaca59955fc785ab /httpd.c
parent32ce4b065911ef73f584691506698a1b1d6de23a (diff)
parentc3fb6bab77f35be6cda261f257b8731d38e5265f (diff)
Merge pull request 'Improve support for Mona iOS app' (#100) from jamesoff/snac2:monaapp-support into master
Reviewed-on: https://codeberg.org/grunfink/snac2/pulls/100
Diffstat (limited to 'httpd.c')
-rw-r--r--httpd.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/httpd.c b/httpd.c
index ecb64b4..4c6d985 100644
--- a/httpd.c
+++ b/httpd.c
@@ -344,6 +344,14 @@ void httpd_connection(FILE *f)
if (strcmp(method, "OPTIONS") == 0) {
status = 200;
}
+ else
+ if (strcmp(method, "DELETE") == 0) {
+#ifndef NO_MASTODON_API
+ if (status == 0)
+ status = mastoapi_delete_handler(req, q_path,
+ &body, &b_size, &ctype);
+#endif
+ }
/* unattended? it's an error */
if (status == 0) {