I2P Address: [http://git.idk.i2p]

Skip to content
Snippets Groups Projects
Unverified Commit 7048ba67 authored by zzz's avatar zzz
Browse files

i2psnark: Change js mime type as per RFC 9239

parent 894a2d64
No related branches found
No related tags found
No related merge requests found
Pipeline #1351 failed
......@@ -395,11 +395,11 @@ class BasicServlet extends HttpServlet
String rtype = response.getContentType();
String ctype = content.getContentType();
if (rtype != null) {
if (rtype.equals("application/javascript"))
if (rtype.contains("javascript"))
response.setCharacterEncoding("ISO-8859-1");
} else if (ctype != null) {
response.setContentType(ctype);
if (ctype.equals("application/javascript"))
if (ctype.contains("javascript"))
response.setCharacterEncoding("ISO-8859-1");
}
response.setHeader("X-Content-Type-Options", "nosniff");
......
......@@ -12,6 +12,7 @@ epub = application/epub+zip
flac = audio/flac
flv = video/x-flv
iso = application/x-iso9660-image
js = text/javascript
jxl = image/jxl
m3u = audio/mpegurl
m3u8 = audio/mpegurl
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment