afb-hreq: Add json to known mimetypes
authorLoïc Collignon <loic.collignon@iot.bzh>
Thu, 30 Nov 2017 10:47:15 +0000 (11:47 +0100)
committerJosé Bollo <jose.bollo@iot.bzh>
Thu, 18 Jan 2018 09:12:00 +0000 (10:12 +0100)
Change-Id: Ic11ebf7e569160dd25e66a1273904dfcd82bdeb8
Signed-off-by: Loïc Collignon <loic.collignon@iot.bzh>
src/afb-hreq.c

index 5f44cba..a8aae40 100644 (file)
@@ -272,6 +272,7 @@ static const char *mimetype_fd_name(int fd, const char *filename)
        if (extension) {
                static const char *const known[][2] = {
                        { ".js",        "text/javascript" },
+                       { ".json",      "application/json" },
                        { ".html",      "text/html" },
                        { ".css",       "text/css" },
                        { ".ico",       "image/x-icon"},