mirror of
https://github.com/lifegpc/eh-downloader.git
synced 2026-06-29 07:26:47 +08:00
Add mimetype for .js.map
This commit is contained in:
@@ -62,6 +62,9 @@ export async function handler(req: Request, ctx: MiddlewareHandlerContext) {
|
||||
const opts: GetFileResponseOptions = {};
|
||||
opts.range = req.headers.get("Range");
|
||||
opts.if_modified_since = req.headers.get("If-Modified-Since");
|
||||
if (file.endsWith(".js.map")) {
|
||||
opts.mimetype = "application/json";
|
||||
}
|
||||
return get_file_response(file, opts);
|
||||
}
|
||||
const res = await ctx.next();
|
||||
|
||||
Reference in New Issue
Block a user