diff options
author | Omar Polo <op@omarpolo.com> | 2022-04-08 15:25:50 +0000 |
---|---|---|
committer | Omar Polo <op@omarpolo.com> | 2022-04-08 15:25:50 +0000 |
commit | 8fb0df4d79c26e54d57fd0d4e35bc1ae2954de20 (patch) | |
tree | 13beba77482132fea0bd6571e3918b709acd8d12 /mime.c | |
parent | 99a95569a4e95e04600690734fef072cbf19b572 (diff) |
hardcode the mapping text/gemini -> .gmi/.gemini
It's still possible to override this automatic mapping by just adding
an entry like
application/octet-stream gemini gmi
in the `types' block.
Diffstat (limited to 'mime.c')
-rw-r--r-- | mime.c | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -149,6 +149,8 @@ mime(struct vhost *host, const char *path) mime_find); if (t != NULL) return t->mime; + if (!strcmp(ext, "gmi") || !strcmp(ext, "gemini")) + return "text/gemini"; return def; } |