mirror of
https://github.com/AUTOMATIC1111/stable-diffusion-webui.git
synced 2024-12-29 19:05:05 +08:00
Merge pull request #15654 from huchenlei/mime
Add correct mimetype for .mjs files
This commit is contained in:
commit
569f17c6c6
@ -38,6 +38,7 @@ warnings.filterwarnings("default" if opts.show_gradio_deprecation_warnings else
|
|||||||
# this is a fix for Windows users. Without it, javascript files will be served with text/html content-type and the browser will not show any UI
|
# this is a fix for Windows users. Without it, javascript files will be served with text/html content-type and the browser will not show any UI
|
||||||
mimetypes.init()
|
mimetypes.init()
|
||||||
mimetypes.add_type('application/javascript', '.js')
|
mimetypes.add_type('application/javascript', '.js')
|
||||||
|
mimetypes.add_type('application/javascript', '.mjs')
|
||||||
|
|
||||||
# Likewise, add explicit content-type header for certain missing image types
|
# Likewise, add explicit content-type header for certain missing image types
|
||||||
mimetypes.add_type('image/webp', '.webp')
|
mimetypes.add_type('image/webp', '.webp')
|
||||||
|
Loading…
Reference in New Issue
Block a user